+ Reply to Thread
Results 1 to 3 of 3

Tidyup of IF formula

  1. #1
    Big Rick
    Guest

    Tidyup of IF formula

    Hello folks.

    I have the following formula that does do the the required job.
    Is it possible for it to be 'tidied up', possibly with a lookup formula.

    =IF(Apr!$C5="","X",IF(Apr!$C5="Holiday","Hol.",IF(Apr!$C5="Sick","Sick",IF(Apr!$C5="Worked","Work",IF(Apr!$C5="Day
    Off","D / O",IF(Apr!$C5="Wrk & 1/2 Hol","½ Hol.",""))))))

    Your help is and always has been very much appreciated.
    Thanking you in anticipation.
    --
    Big Rick

  2. #2
    Peo Sjoblom
    Guest

    Re: Tidyup of IF formula

    If you create a table like this

    Holiday Hol
    Sick Sick
    Worked Work
    Day Off D / O
    Wrk $ 1/2 Hol" 1/2 Hol


    put it somewhere off view maybe Y1:Z5 then you can use

    =IF(Apr!$C5="","X",VLOOKUP(Apr!C5,Y1:Z5,2,0))

    hard coded it would look like

    =IF(Apr!$C5="","X",VLOOKUP(Apr!C5,{"Holiday","Hol";"Sick","Sick";"Worked","Work";"Day
    Off","D / O";"Wrk $ 1/2 Hol""","1/2 Hol"},2,0))



    --

    Regards,

    Peo Sjoblom


    "Big Rick" <[email protected]> wrote in message
    news:[email protected]...
    > Hello folks.
    >
    > I have the following formula that does do the the required job.
    > Is it possible for it to be 'tidied up', possibly with a lookup formula.
    >
    > =IF(Apr!$C5="","X",IF(Apr!$C5="Holiday","Hol.",IF(Apr!$C5="Sick","Sick",IF(Apr!$C5="Worked","Work",IF(Apr!$C5="Day
    > Off","D / O",IF(Apr!$C5="Wrk & 1/2 Hol","½ Hol.",""))))))
    >
    > Your help is and always has been very much appreciated.
    > Thanking you in anticipation.
    > --
    > Big Rick




  3. #3
    Big Rick
    Guest

    Re: Tidyup of IF formula

    Dear Peo.
    I bow down to your superiority.

    Fantastic. Thank you very much.
    --
    Big Rick


    "Peo Sjoblom" wrote:

    > If you create a table like this
    >
    > Holiday Hol
    > Sick Sick
    > Worked Work
    > Day Off D / O
    > Wrk $ 1/2 Hol" 1/2 Hol
    >
    >
    > put it somewhere off view maybe Y1:Z5 then you can use
    >
    > =IF(Apr!$C5="","X",VLOOKUP(Apr!C5,Y1:Z5,2,0))
    >
    > hard coded it would look like
    >
    > =IF(Apr!$C5="","X",VLOOKUP(Apr!C5,{"Holiday","Hol";"Sick","Sick";"Worked","Work";"Day
    > Off","D / O";"Wrk $ 1/2 Hol""","1/2 Hol"},2,0))
    >
    >
    >
    > --
    >
    > Regards,
    >
    > Peo Sjoblom
    >
    >
    > "Big Rick" <[email protected]> wrote in message
    > news:[email protected]...
    > > Hello folks.
    > >
    > > I have the following formula that does do the the required job.
    > > Is it possible for it to be 'tidied up', possibly with a lookup formula.
    > >
    > > =IF(Apr!$C5="","X",IF(Apr!$C5="Holiday","Hol.",IF(Apr!$C5="Sick","Sick",IF(Apr!$C5="Worked","Work",IF(Apr!$C5="Day
    > > Off","D / O",IF(Apr!$C5="Wrk & 1/2 Hol","½ Hol.",""))))))
    > >
    > > Your help is and always has been very much appreciated.
    > > Thanking you in anticipation.
    > > --
    > > Big Rick

    >
    >
    >


+ 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