+ Reply to Thread
Results 1 to 2 of 2

Macro to choose which formula to use.

  1. #1
    Forum Contributor
    Join Date
    04-03-2009
    Location
    USA, California
    MS-Off Ver
    Excel 2007
    Posts
    385

    Macro to choose which formula to use.

    Basically I need to have a macro fill in a formula based on if a value exists.

    So for this example cell M2 contains the following formula:
    Please Login or Register  to view this content.
    And cell N2 contains the following formula:

    Please Login or Register  to view this content.
    What I need is someway to check if $J$2-d2 >2

    Cell L2 contains the difference between the employees time and the average shift length. (which would be the number 2 after the > in the example above)

    If there would be anyway of making the number 2 variable with the use of a text box or something that would be even better.
    Last edited by randell.graybill; 05-07-2009 at 09:25 PM.

  2. #2
    Forum Contributor
    Join Date
    04-03-2009
    Location
    USA, California
    MS-Off Ver
    Excel 2007
    Posts
    385

    Re: Macro to choose which formula to use.

    I solved this using an IF formula to check if cell L2 was blank if it was the formula used the value from M2 if it wasn't blank it used the value from N2.

+ 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