+ Reply to Thread
Results 1 to 10 of 10

Lost format after pasting

  1. #1
    Forum Contributor
    Join Date
    08-19-2006
    Posts
    116

    Lost format after pasting

    Hi all

    I have two files: let's say File1 and File2.File1 has one column: datas are in a text format.I copy this column. I want to paste it in my second file.File2 is closed.I open it and i paste my column.
    Here's my problem. If i let my first file opened, there's no problem(!!): my column is pasted as i want. My datas keep their original format.
    But, if i close my first file and after, i open File2 and i paste my column, then my datas lose their original format.My column takes a numeric format.I can see it because my datas are on the left in the column.And i can chek it by a sum: if i do 400+200, for example, the result is 600. In the first case(text format), the result is 0.I don't understand why.If someone can explain me this situation, i'd be happy.I repeat: my second file is closed. I open it after my copy in the first file.

    Thanks in advance for your help.
    Last edited by VBA Noob; 10-11-2007 at 02:34 AM.

  2. #2
    Valued Forum Contributor
    Join Date
    02-09-2006
    Location
    Melbourne, Australia
    MS-Off Ver
    Office 2016
    Posts
    1,075
    Try using Paste Special instead of just pasting. After you open file2, right click on the cell where you will paste and select Paste Special, click on the Values or Text option, then click OK. The pasted data will keep the format of the cell it is being pasted into, so it needs to be formatted before you paste.
    Trish in Oz
    -------------
    A problem well defined is a puzzle half solved


    If you attach a sample of your workbook it will be easier to find a solution. Remember to remove/replace sensitive data before uploading the file. Look here if you need help with attachments:
    http://www.excelforum.com/faq.php?fa...b3_attachments

  3. #3
    Forum Contributor
    Join Date
    08-19-2006
    Posts
    116
    Quote Originally Posted by tuph
    Try using Paste Special instead of just pasting. After you open file2, right click on the cell where you will paste and select Paste Special, click on the Values or Text option, then click OK. The pasted data will keep the format of the cell it is being pasted into, so it needs to be formatted before you paste.
    Hi Tuph

    Thanks for your answer. I know your solution and i have tried it but my problem is that when i open the menu Paste Special, i don't see the menu with the following options: All, Formulas,Values,Formats, and so on. What i see in fact is a Paste Special dialog box with 2 options: Unicod Text and Text.I see also "Inserts the contents of the Clipboard as a unicode text". Anyway, when my first file is opened, my pasting is good.It doesn't work if i close my first file.It's strange. Isn't it?I try to be clear even i don't speak english.If you see my problem (i don't speak english very well), i wait your solution. Thanks again.
    Last edited by Raiby; 10-12-2007 at 02:58 AM.

  4. #4
    Forum Contributor
    Join Date
    03-23-2007
    Location
    Essex, UK
    MS-Off Ver
    Office Pro 2010
    Posts
    275
    Can u post a small example of what u are trying to do

  5. #5
    Forum Contributor
    Join Date
    08-19-2006
    Posts
    116
    Quote Originally Posted by ukphoenix
    Can u post a small example of what u are trying to do
    See my screenshots.
    Attached Files Attached Files

  6. #6
    Registered User
    Join Date
    10-12-2007
    Posts
    21
    Are your two files being opened in the same "Excel" environment?


    I may not explain it right; but with Excel 2003, at least, you can open multiple workbooks in Excel or yo can also open a completely different Excel.

  7. #7
    Valued Forum Contributor
    Join Date
    02-09-2006
    Location
    Melbourne, Australia
    MS-Off Ver
    Office 2016
    Posts
    1,075
    Quote Originally Posted by Raiby
    See my screenshots.
    If the format is kept when you leave file 1 open, that's the answer - keep file 1 open while pasting.

  8. #8
    Forum Contributor
    Join Date
    08-19-2006
    Posts
    116
    Quote Originally Posted by Oscar
    Are your two files being opened in the same "Excel" environment?
    I may not explain it right; but with Excel 2003, at least, you can open multiple workbooks in Excel or yo can also open a completely different Excel.
    First, i owe you an apology. I wrote:"my numeric data is on the left".Of course, it's on the right in the cell.My text format is on the left.I meet the same problem with excel 97 and excel 2003.But to say the truth, i don't understand what you mean by opening a completely different excel.(two excel on the machine?).I meet my problem when I open the two files: the first, i copy it and after without closing it,i open the second file.Each file is a workbook.So i can say that i open multiple workbooks.

  9. #9
    Registered User
    Join Date
    10-12-2007
    Posts
    21
    sorry, away for awhile, don't get here often.

    i mean you can open a workbook from within excel or you can open a new Excel window and then open the othe spreadsheet. It makes a difference.

    I don't know the terminology
    But if you have two "different Excels" open, you won't see all the same spreadsheets listed in the "Window" menu on the top tool bar

  10. #10
    Forum Contributor
    Join Date
    08-19-2006
    Posts
    116
    [QUOTE=i mean you can open a workbook from within excel or you can open a new Excel window and then open the othe spreadsheet. It makes a difference.
    I don't know the terminology
    But if you have two "different Excels" open, you won't see all the same spreadsheets listed in the "Window" menu on the top tool bar[/QUOTE]

    No problem for the time frame .
    I see now what you mean.It's the same excel.I open my first file and i copy my column.Then,i open my second file and i paste my column.I don't open a second excel.I am on the second file:in the window menu, i see the names of my 2 files
    File2 with a tick before (this file is my file activated)
    File1

    It's not a big problem :as says tuph,i can let my first file open.But i just want to understand why i meet this problem in a case.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1