VBA to pick up data and conditionally format based on lookup criteria

  • Hi,

    Have formulae to collect the data from it's raw data source then display it in an alternative layout with visual keys created using conditional formatting. Issue is it's too clunky on the machines so thinking vba (via a button) that looks for new information to add/ conditionally format each time may be less clunky?

    Attached is the Raw Data (Site check log tab) and the output I am looking to do using VBA (Site check visual). At the moment it pulls the data from the raw data table into the format, then in conditional formatting indexes the Site and Date against the raw table to pick up the rating and colour the cell containing the date of the check accordingly.

    I had a go at starting to write something that would do the conditional formatting of the whole sheet at once each time, but realised that the method I was attempting would need to loop through more than one variable (which I am not sure how to do).

    Ultimately the script would be able to check the raw data table and only add new information to the summary, and the conditional formatting would do the same- looking up the raw data table for only cells in the summary where a date is contained but with a white/ no background colour.

    In order for the script to know if it is new data, if it needs to mark in another column on the Raw data table that it has previously picked up certain rows of data then that is fine to do.

    Thanks in advance for the help. [ATTACH]n1201689[/ATTACH]

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!