+ Reply to Thread
Results 1 to 4 of 4

Pasting values not formulas from one sheet into a second sheet

  1. #1
    Registered User
    Join Date
    04-08-2012
    Location
    Sydney
    MS-Off Ver
    Excel 2007
    Posts
    31

    Pasting values not formulas from one sheet into a second sheet

    Hi,

    Can someone please help me with the VBA code below that is giving me syntax error:

    *****************************************
    Worksheets("sheet1").Range("A1").Copy _
    Destination:=Range("A65536").End(xlUp).Offset(1, 0).PasteSpecial Paste:=xlValues, Operation:=xlNone, SkipBlanks:=False, Transpose:=False
    ****************************

    what i want the code to do is:


    in sheet 1:
    a1= (b1+c1) where b1 and c1 are values i will be keying in

    so for example:
    a1=2 (b1=1,c1=1)
    a1=3 (b1=2,c1=1)
    a1=4 (b1=2,c1=2)

    in sheet 2:
    a1=2 from sheet 1
    a2=3 from sheet 1
    a3=4 from sheet 1


    I want the addition of b1 and c1, to be inserted in Column A of sheet 2 .I dont want the values to over write and dont want the formula to be transferred over. And if the code could support unlimited number of entries that would be awesome

    Thank you for your time in advance

  2. #2
    Registered User
    Join Date
    09-14-2008
    Location
    Chester, IL
    Posts
    7

    Re: Pasting values not formulas from one sheet into a second sheet

    If you want to pastespecial, you have to use 2 lines. Try this out:

    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    04-08-2012
    Location
    Sydney
    MS-Off Ver
    Excel 2007
    Posts
    31

    Re: Pasting values not formulas from one sheet into a second sheet

    Thank you so much!! It worked.

    Cheers,

  4. #4
    Registered User
    Join Date
    09-14-2008
    Location
    Chester, IL
    Posts
    7

    Re: Pasting values not formulas from one sheet into a second sheet

    No problem. Glad to help

+ 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