+ Reply to Thread
Results 1 to 5 of 5

Formula needed for conditional formatting between time range over 2 columns

Hybrid View

  1. #1
    Registered User
    Join Date
    09-30-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    9

    Formula needed for conditional formatting between time range over 2 columns

    Hi all,

    I have sat on this for a day now googling has not been successful and could really use your expertise in tweaking the formula. I'm trying to apply conditional formatting to 2 columns if the time falls between assigned times.

    This formula is only partially working and is not picking up all times between 10:45-11:30.

    =AND ($K2> TIME(10,4,5), $L2 < TIME(11,3,0)) - there are spaces in between because Scuri detects it's a HTML and won't allow me to post this thread

    Example: So in the below list, K2:L2, K3:L3 would be highlighted but K1:L1 and K4:L4 does not because it falls outside of specified conditions of 10:45 - 11:30.
    Column K Column L
    1 10:15 10:30
    2 10:45 11:15
    3 11:00 11:30
    4 11:15 11:50

    Thanks in advance

  2. #2
    Forum Expert Crooza's Avatar
    Join Date
    10-19-2013
    Location
    Hunter Valley, Australia
    MS-Off Ver
    Excel 2003 /7/10
    Posts
    2,082

    Re: Formula needed for conditional formatting between time range over 2 columns

    The time function is Hours, minutes, seconds. If you want 10:45 I would change time(10,4,5) to time(10,45,0) and likelwise for 11:30 time (11,30,0)
    Happy with my advice? Click on the * reputation button below

  3. #3
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,893

    Re: Formula needed for conditional formatting between time range over 2 columns

    Try this conditional formatting rule:
    Formula: copy to clipboard
    =AND($K1>=TIME(10,45,0),$L1<=TIME(11,30,0))
    Note: you can delete M1:M4
    Let me know if you have any questions.
    Attached Files Attached Files
    Consider taking the time to add to the reputation of everybody that has taken the time to respond to your query.

  4. #4
    Registered User
    Join Date
    09-30-2013
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    9

    Re: Formula needed for conditional formatting between time range over 2 columns

    Thanks so much Crooza and JeteMc (thanks for going the extra mile with providing an example)

  5. #5
    Forum Guru
    Join Date
    08-28-2014
    Location
    USA
    MS-Off Ver
    Excel 365 version 2501
    Posts
    18,893

    Re: Formula needed for conditional formatting between time range over 2 columns

    You're Welcome and thank you for the feedback. Please take a moment to mark the thread 'Solved' using the thread tools link above your first post. I hope that you have a blessed day.

+ 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] Help please! Formula needed for conditional formatting.
    By SLIDE1 in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-24-2016, 12:23 PM
  2. Conditional formatting formula needed
    By freckles81 in forum Excel General
    Replies: 6
    Last Post: 05-29-2014, 10:34 AM
  3. [SOLVED] Conditional Formatting formula needed!
    By kgowett in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-11-2014, 03:47 PM
  4. Formula needed for conditional formatting
    By NEHicks in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 02-22-2013, 11:28 AM
  5. Conditional Formatting Formula Needed
    By AJT82 in forum Excel General
    Replies: 2
    Last Post: 10-08-2011, 05:15 AM
  6. Conditional formatting formula help needed
    By gloworm in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-15-2011, 03:12 PM
  7. Conditional Formatting using formula needed for the following problem
    By Deepthik in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 05-29-2010, 09:41 AM

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