+ Reply to Thread
Results 1 to 5 of 5

Macro to Copy & Paste

  1. #1
    Registered User
    Join Date
    02-06-2012
    Location
    NYC, US
    MS-Off Ver
    Excel 2010
    Posts
    19

    Macro to Copy & Paste

    I have a bunch of formulas in D10:P10 that I want pasted on a row specified by the user.

    Note: theRow is a number that has already been specified by the user by working code.
    The following code gives me an "object doesn't support this property or method" error.

    Please Login or Register  to view this content.
    Last edited by juliorevka; 03-06-2012 at 03:03 PM.

  2. #2
    Forum Expert DGagnon's Avatar
    Join Date
    02-23-2012
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2003, 2007
    Posts
    1,645

    Re: Macro to Copy & Paste

    you droped one " after P10, added it in bellow, give it a run.

    Please Login or Register  to view this content.
    If you liked my solution, please click on the Star -- to add to my reputation

    If your issue as been resolved, please clearly state so and mark the thread as [SOLVED] using the thread tools just above the first post.

  3. #3
    Registered User
    Join Date
    02-06-2012
    Location
    NYC, US
    MS-Off Ver
    Excel 2010
    Posts
    19

    Re: Macro to Copy & Paste

    It's not that, but I ended up figuring it out. I needed to paste onto the sheet rather than the selection.

    But now I have another problem. I want to loop through every worksheet, and copy & paste formulas on every tab. But I get a "select method of range class failed" error.

    Please Login or Register  to view this content.

  4. #4
    Forum Expert DGagnon's Avatar
    Join Date
    02-23-2012
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2003, 2007
    Posts
    1,645

    Re: Macro to Copy & Paste

    you need to select the worksheet before you can select a range within the sheet, try this:

    Please Login or Register  to view this content.
    Last edited by DGagnon; 03-06-2012 at 06:15 PM.

  5. #5
    Forum Expert DGagnon's Avatar
    Join Date
    02-23-2012
    Location
    Ontario, Canada
    MS-Off Ver
    Excel 2003, 2007
    Posts
    1,645

    Re: Macro to Copy & Paste

    Is your issue resolved? If your problem is solved, please say so clearly, and mark your thread as Solved: Click the Edit button on your first post in the thread, Click Go Advanced, select [SOLVED] from the Prefix dropdown, then click Save Changes. If more than two days have elapsed, the Edit button will not appear -- ask a moderator to mark it.

+ 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