+ Reply to Thread
Results 1 to 3 of 3

VBA cell formatting and index match replacement

  1. #1
    Forum Contributor
    Join Date
    02-07-2013
    Location
    London
    MS-Off Ver
    Excel 2019
    Posts
    105

    VBA cell formatting and index match replacement

    Hi Everyone, hope you are having a blessed day!

    I am trying to improve my holiday tracking workbook.
    I would like VBA code to:

    a) change cell interior colour if employee is not in employment (to affect K8:v30) to replace my existing conditional formatting
    b) replace index match function to vba code (in K8:v30)

    I am attaching sample workbook.

    Formatting for a)
    Currently i have simple conditional formatting
    Please Login or Register  to view this content.
    Formula for b) in cells K8:v30
    Please Login or Register  to view this content.
    is it something that is possible?
    I am searching the web trying case vba, ranges but i am completely lost.

    Thank you for your help in advance!
    Last edited by annazet; 10-04-2018 at 07:09 AM. Reason: changed approach new thread to start

  2. #2
    Forum Expert Tsjallie's Avatar
    Join Date
    09-15-2012
    Location
    NL
    MS-Off Ver
    2010, 2013, 2016
    Posts
    2,077

    Re: VBA cell formatting and index match replacement

    If you swap 0 and 1 in yr formula for conditional formatting it'll work fine.
    But actually the formula could be just this:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    It's all abot the result being True (or 1)or False (or 0)

    I'm not sure what you would like to improve in the formula for K8:V30.
    Works fine, though I can imagine that you would like it to be more flexible or generic.
    In that case I would focus on restructuring the M01, M02 etc sheets. E.g. converting the data ranges to tables would allow for referencing tables instead of sheetnames. Also no worries about rows and columns referencing.
    I'm attaching an example of what I mean. Sheets M01 and M02 replaced by 1 sheet Data.

    It really puzzles me why you would want the formulas replaced by vba
    Cheers!
    Tsjallie




    --------
    If your problem is solved, pls mark the thread SOLVED (see Thread Tools in the menu above). Thank you!

    If you think design is an expensive waste of time, try doing without ...

  3. #3
    Forum Contributor
    Join Date
    02-07-2013
    Location
    London
    MS-Off Ver
    Excel 2019
    Posts
    105

    Re: VBA cell formatting and index match replacement

    Hi, Thank you for your response.
    I have came up with a different approach no VBA.
    I will mark this as solved and start another thread, hope not to confuse anyone too much.

+ 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. [SOLVED] Index/Aggregate/row match with conditions, pivot summary replacement
    By Shruder in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 04-19-2018, 08:36 AM
  2. Huge data index/match replacement
    By teireii in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 07-31-2017, 03:33 AM
  3. Huge data index/match replacement
    By teireii in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-26-2017, 05:44 AM
  4. Replies: 2
    Last Post: 05-24-2016, 08:10 PM
  5. Cell Formatting not working - breaks INDEX/Match
    By fsnox in forum Excel General
    Replies: 1
    Last Post: 01-26-2016, 01:30 PM
  6. [SOLVED] vba replacement for index match array
    By eculver in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 11-05-2015, 05:39 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