+ Reply to Thread
Results 1 to 5 of 5

Populating Cell Range Based on Data from Two Different Columns

  1. #1
    Registered User
    Join Date
    10-20-2012
    Location
    salinas, ca
    MS-Off Ver
    Excel 2010
    Posts
    25

    Populating Cell Range Based on Data from Two Different Columns

    Hello everyone,

    I need your help resolving this particular problem: I need to change the data in a range of cells in a column without changing the rest of the cells in that same column. Please take a look at the attached sample file.

    I use a form to help the user input the data on the spreadsheet; the supervisor would look at the sheet at the end of the day and approved it if no problems were found... I have another userform to help with that as well. This userform takes a look at column A (range A6:A250) for a date and places the supervisor's name on column G (range G6:G250) if the data is present. At least that's the way it worked before... now the supervisors must look at the sheet at different times during the day and check it for errors... if none are found, then they need to sign off on it, along with a time stamp for that inspection. A few hours later another supervisor may take a look at the data and sign off on the work done up to his inspection... but the previous check must remain intact.

    So, the problem is this: how can I populate a specific range in Column G without changing other parts in the same column? The userform must search for a date stamp on column A, then place the supervisor's name in column G without changing the name above the next empty cell in column G... based on whether or not there's a date in that same row located in column A.

    On the sample sheet, you can see that supervisor Pink Panther approved the work done up to his inspection... what modifications to the code can I make so that the next supervisor can approve the other work without changing Pink's approvals?

    Any help resolving this problem will be greatly appreciated!!

    Thanks in advance...

    Julian
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,565

    Re: Populating Cell Range Based on Data from Two Different Columns

    Hi Julez80s,

    Is this what you're after??:

    Please Login or Register  to view this content.
    Regards,

    Robert
    ____________________________________________
    Please ensure you mark your thread as Solved once it is. Click here to see how
    If this post helps, please don't forget to say thanks by clicking the star icon in the bottom left-hand corner of my post

  3. #3
    Registered User
    Join Date
    10-20-2012
    Location
    salinas, ca
    MS-Off Ver
    Excel 2010
    Posts
    25

    Re: Populating Cell Range Based on Data from Two Different Columns

    Hi Robert!

    Thank you for the prompt response to the issue... your solution worked perfectly! I was working on something similar but your code is much more functional than what I had so far... your solution is simple, elegant and best of all, it works really well.

    Could I trouble you for an explanation on the use of the * character in the "lngLastRow =" line?

    Thanks again for the help!!

    Julian

  4. #4
    Forum Expert
    Join Date
    12-10-2006
    Location
    Sydney
    MS-Off Ver
    Office 365
    Posts
    3,565

    Re: Populating Cell Range Based on Data from Two Different Columns

    Hi Julian,

    The asterisk in that line is a wildcard to find the last piece of any data type across columns A to G.

    I'm glad we got it sorted for you. Thanks for marking the thread as solved and for the rep

    Cheers,

    Robert

  5. #5
    Registered User
    Join Date
    10-20-2012
    Location
    salinas, ca
    MS-Off Ver
    Excel 2010
    Posts
    25

    Re: Populating Cell Range Based on Data from Two Different Columns

    Thanks again for the help Robert... you saved me from a lot of headaches on this one!

    Julian

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Replies: 8
    Last Post: 07-12-2015, 09:45 AM
  2. Populating a range based on cell value
    By gazlatic in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 12-17-2014, 01:54 PM
  3. Populating various cells in a range based on a table of cell addresses
    By cm115 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 01-28-2013, 02:55 PM
  4. Populating a cell based on the value of another + a range
    By isomagaz in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 11-05-2012, 10:24 AM
  5. Populating a userform based on a range of 3 columns
    By JimmyA in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 03-02-2012, 12:41 PM
  6. Replies: 10
    Last Post: 04-27-2010, 11:31 AM
  7. Populating a cell based on combobox data
    By mrdata in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 07-18-2006, 05:29 PM

Tags for this Thread

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