+ Reply to Thread
Results 1 to 4 of 4

Paste a value in a specified location

  1. #1
    Registered User
    Join Date
    12-06-2012
    Location
    Sthl, Sweden
    MS-Off Ver
    Excel 2007
    Posts
    2

    Post Paste a value in a specified location

    In cell A2 I have a cell reference, which indicates where in the excel sheet a copied value should be pasted (The value in A2 is changeable depending on the number of lines used). I have built a macro that copies a range of values ​​in column M and that shall be pasted in the location specified in A2, in this case Y532. But apparently it's not enough to do as I have done below. What am I doing wrong?

    Range("M9").Select
    Range(Selection, Selection.End(xlDown)).Select
    Selection.Copy
    Range("A2").Value.Select
    Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
    :=False, Transpose:=False

    Hopefully someone can help me.

  2. #2
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Paste a value in a specified location

    instead of
    Please Login or Register  to view this content.
    use
    Please Login or Register  to view this content.
    Josie

    if at first you don't succeed try doing it the way your wife told you to

  3. #3
    Registered User
    Join Date
    12-06-2012
    Location
    Sthl, Sweden
    MS-Off Ver
    Excel 2007
    Posts
    2

    Re: Paste a value in a specified location

    It works! I'm so grateful! Thanks.

  4. #4
    Forum Guru JosephP's Avatar
    Join Date
    03-27-2012
    Location
    Ut
    MS-Off Ver
    2003/10
    Posts
    7,328

    Re: Paste a value in a specified location

    you're welcome :-)

    If you are satisfied with the solution(s) provided, please mark your thread as Solved.


    New quick method:
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

    Or you can use this way:

    How to mark a thread Solved
    Go to the first post
    Click edit
    Click Go Advanced
    Just below the word Title you will see a dropdown with the word No prefix.
    Change to Solved
    Click Save

+ 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