+ Reply to Thread
Results 1 to 4 of 4

Copy SubAmount

  1. #1
    Registered User
    Join Date
    07-16-2010
    Location
    LA, CA
    MS-Off Ver
    Excel 2003
    Posts
    9

    Copy SubAmount

    I have this code which works fine but I just couldn't figure it out how can I copy the content of "SubAmount" to the cell on the left of it and the "SubAmount" are randomly on various cells on Column F . any help would be appreciated.
    For instance:
    the SubAmount on F10 ---> copy to E10
    F13----> copy to E13
    and so on..
    Please Login or Register  to view this content.

  2. #2
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,596

    Re: Copy SubAmount

    SubAmount is a variable defined in the code.

    In the loop,

    Please Login or Register  to view this content.

    determines which row, R+1, and which column, F, are used as the cell reference.

    So, if you want to put something in column E on the same row, use:

    Please Login or Register  to view this content.

    If you want to put the SubAmount value in column E rather than column F, just change the code to:

    Please Login or Register  to view this content.


    Regards
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  3. #3
    Registered User
    Join Date
    07-16-2010
    Location
    LA, CA
    MS-Off Ver
    Excel 2003
    Posts
    9

    Re: Copy SubAmount

    TMShucks,

    You're the best. You just resolved my nightmare. Thanks.

  4. #4
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    48,596

    Re: Copy SubAmount

    You're welcome. Thanks for the feedback.

+ 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