+ Reply to Thread
Results 1 to 6 of 6

Check cell Value in range and copy specific cells to another sheet

  1. #1
    Registered User
    Join Date
    08-23-2012
    Location
    GC, QLD
    MS-Off Ver
    Excel 2007
    Posts
    12

    Check cell Value in range and copy specific cells to another sheet

    Hi

    I am getting stuck in some illogical thinking in my logic.

    I am hoping someone can review the attached document and provide some feedback on how to make the following work:

    If cell in range = true
    Copy selected Cells from sheet A to selected cells on sheet B

    My code was working but unfortunately the logic of the code was wrong.

    I was successfully checking the range and when true it would copy the first row as originally set in the first part of the code. Then when the cell was true the next time my code was incrementing by one so it would copy the next row not the one that was actually true.

    I admit that I butchered some code from previous forms.

    All is attached in the spreadsheet - Please refer to Module2
    Attached Files Attached Files
    jmetheJEDI

  2. #2
    Valued Forum Contributor
    Join Date
    03-22-2013
    Location
    Australia,NSW, Wirrimbi
    MS-Off Ver
    Excel 2013
    Posts
    1,057

    Re: Check cell Value in range and copy specific cells to another sheet

    Hi..

    Try changing the code you have in the Sub DocIndex() to this..
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    08-23-2012
    Location
    GC, QLD
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Check cell Value in range and copy specific cells to another sheet

    Hi Apo

    Thanks for that. Works great except it is not picking up the MA.Cells(LastRow2, 4) for the document number.

    Are you able to shed any light on that?

  4. #4
    Registered User
    Join Date
    08-23-2012
    Location
    GC, QLD
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Check cell Value in range and copy specific cells to another sheet

    Hi There

    I do have another issue.

    I would like to create a count. Where the item CT = 001 I actually want to be able to increment the number on the document number if the Acronym has already been used.

    Example.

    Item Type = Quality and is first one = 12345-Q-001
    Item Type = Quality and is second one = 12345-Q-002

    How could I achieve that?

  5. #5
    Valued Forum Contributor
    Join Date
    03-22-2013
    Location
    Australia,NSW, Wirrimbi
    MS-Off Ver
    Excel 2013
    Posts
    1,057

    Re: Check cell Value in range and copy specific cells to another sheet

    Hi..

    For this part..

    Works great except it is not picking up the MA.Cells(LastRow2, 4) for the document number.
    Change this..
    Please Login or Register  to view this content.
    to this..

    Please Login or Register  to view this content.
    As for this part...
    I would like to create a count. Where the item CT = 001 I actually want to be able to increment the number on the document number if the Acronym has already been used.
    I think you would have to create a Count for each Acronym... and set CT to the count value + 1 of the specific Acronym..

    I will have to think on it.. hopefully someone else gives you a solution to that sooner..

  6. #6
    Registered User
    Join Date
    08-23-2012
    Location
    GC, QLD
    MS-Off Ver
    Excel 2007
    Posts
    12

    Re: Check cell Value in range and copy specific cells to another sheet

    Thank you for the help you have provided thus far. Everything is working great - now to work out this count....

+ 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