+ Reply to Thread
Results 1 to 4 of 4

code for variable filepath

  1. #1
    Registered User
    Join Date
    05-15-2008
    Posts
    11

    code for variable filepath

    Good day fellas.

    I would appreciate some wisdom from the mountain. I have been trying to write a copy paste macro. I was wondering if I could write most of the filepath into the VBA code, but have excel read the rest of it from a cell on the active sheet (or maybe an input box?). This way I can use the same macro to cut and paste certain ranges from from any workbook I want.
    My thanks to the gurus who take the time to enlighten noobs like myself.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678
    Maybe like this:
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    05-15-2008
    Posts
    11
    This is the code I have so far. Where would I add that line? Pretty new to VBA and am pretty much chained to the macro recorder for now.

    Please Login or Register  to view this content.
    thanks

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2003, 2010
    Posts
    40,678
    Doesn't this line already do what you asked?

    Please Login or Register  to view this content.
    However, I think this may be more like what you want:
    Please Login or Register  to view this content.

+ 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