+ Reply to Thread
Results 1 to 6 of 6

How to show start and end of data ranges?

  1. #1
    Registered User
    Join Date
    02-22-2010
    Location
    worksop, england
    MS-Off Ver
    Excel 2007
    Posts
    6

    Thumbs up How to show start and end of data ranges?

    Having trouble figuring out the correct formula to show the start and end of shifts in a staff rota?

    Its probably really easy as it seems quite straightforward. I just cant figure it. DOH!!

    I have attached a short template of the problem. Any help would be much appreciated.
    Attached Files Attached Files
    Last edited by wildeone2010; 02-22-2010 at 08:47 PM. Reason: ITS SOLVED

  2. #2
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: How to show start and end of data ranges?

    Hi wildeone,

    welcome to the forum.

    In one row of the table, for example row 4, put a 6 in column B and in C4 enter

    =b4+0.5

    drag across to AK

    now your start formula is

    =INDEX($B$4:$AK$4,MATCH("CS",B9:AK9,0))

    and your end formula

    =INDEX($B$4:$AK$4,MATCH("CS",B9:AK9,1))+0.5

    hth

  3. #3
    Registered User
    Join Date
    02-22-2010
    Location
    worksop, england
    MS-Off Ver
    Excel 2007
    Posts
    6

    Re: How to show start and end of data ranges?

    Thanks, the formula works great...

    just one last question, the data value won't always be CS, it could be numerous letters, how can i change the formula to check any value other than blank.

    thanks again

  4. #4
    Registered User
    Join Date
    02-22-2010
    Location
    worksop, england
    MS-Off Ver
    Excel 2007
    Posts
    6

    Re: How to show start and end of data ranges?

    Another update.

    I have found by changing "cs" value to "*" the start time calculations adjust to recognize the first nonblank cell which is exactly what i require.

    The problem is the end times dont adjust the same way. they keep giving an NA value.

    I'm stuck.

    Help would be appreciated. Have added the updated template.
    Attached Files Attached Files

  5. #5
    Forum Expert teylyn's Avatar
    Join Date
    10-28-2008
    Location
    New Zealand
    MS-Off Ver
    Excel 365 Insider Fast
    Posts
    11,372

    Re: How to show start and end of data ranges?

    use

    =INDEX($B$4:$AK$4,MATCH("z",B9:AK9,1))+0.5

    That will find the rightmost cell with any kind of text in it.

  6. #6
    Registered User
    Join Date
    02-22-2010
    Location
    worksop, england
    MS-Off Ver
    Excel 2007
    Posts
    6

    Thumbs up Re: How to show start and end of data ranges?

    Thank you very much.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

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