+ Reply to Thread
Results 1 to 2 of 2

Macro to insert cell values in another sheet depending on value and format

  1. #1
    Registered User
    Join Date
    06-29-2005
    Posts
    12

    Macro to insert cell values in another sheet depending on value and format

    I need help with a macro which will take info from a range on one sheet and depending on the format and value of the cell in that range insert details into another sheet. I have attached an example as it is a bit awkward to explain and the details below won’t make any sense without the file.

    Basically I start with sheet “Basement 6309 Block ECG List”. The info is entered on this sheet and the cells are formatted with a colour depending on the zone.
    I have a macro which creates the “Basement Logic Sheet” from another page and sets up all the columns and enters all the required info except for details it takes from “Basement 6309 Block ECG List”.
    I have started to fill out “Basement 6309 Block ECG List” manually to show what I need to achieve.
    It basically needs to look at the range F8:U70 on “Basement 6309 Block ECG List” looking at each cell individually. If the cell value and format is the same as the cell on “Basement Logic Sheet” column D then “Basement Logic Sheet” row of that cell column H8:U8 is completed from the details of column B and C in “Basement 6309 Block ECG List”
    Attached Files Attached Files

  2. #2
    Registered User
    Join Date
    06-29-2005
    Posts
    12

    Re: Macro to insert cell values in another sheet depending on value and format

    Any help on this would be appreciated.

    I have had an idea on how to achieve it but don’t have the wherewithal to put the code together.
    My idea is to start with the range of cells, say Range 1, from Column D8 of Basement Logic Sheet to the last used cell in that column.
    Next create a second range, Range 2, from F8:W30 in Basement 6309 Block ECG List.
    Loop through each cell in range 1.
    For each cell in range 1 loop through each cell in range 2 and check if the values and format are equal If they are equal put Range 2’s corresponding Senor No from Column B and Block from Column C into a temp array. Then use the temp array to fill in the cells in Logic Sheet

    Sounds easy!! But I can’t do it.

+ 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. Macro to copy data from one sheet to another depending on name in first cell
    By subtilty in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-14-2013, 07:44 AM
  2. Replies: 14
    Last Post: 11-14-2012, 11:24 AM
  3. macro: insert specified number of rows depending on referenced cell value
    By cffurillo in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 10-24-2012, 11:37 AM
  4. Macro for printing pages within a sheet depending on cell value
    By antonywalsh in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-25-2012, 04:45 PM

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