Discussions

Expand all | Collapse all

Last Friday of the Current Month

  • 1.  Last Friday of the Current Month

    Posted 23 days ago
    I am needing help in finding a formula for a Formula-Date field to show the last Friday of the Current Month by default when adding a record.  I appreciate any help with this!

    ------------------------------
    Tanya Hammil
    ------------------------------


  • 2.  RE: Last Friday of the Current Month

    Posted 23 days ago
    Try this as a formula date field, and then have a form rule that says if your date field is blank to make it be the value in this field.

    var date LDOM = LastDayOfMonth(today());

    var number DaysToBackUp = IF(
    DayOfweek($LDOM)=5,0,
    DayOfweek($LDOM-days(1))=5,1,
    DayOfweek($LDOM-days(2))=5,2,
    DayOfweek($LDOM-days(3))=5,3,
    DayOfweek($LDOM-days(4))=5,4,
    DayOfweek($LDOM-days(5))=5,5,
    DayOfweek($LDOM-days(6))=5,6);

    $LDOM - Days($DaysToBackUp)

    ------------------------------
    Mark Shnier (YQC)
    Quick Base Solution Provider
    Your Quick Base Coach
    http://QuickBaseCoach.com
    mark.shnier@gmail.com
    ------------------------------



  • 3.  RE: Last Friday of the Current Month

    Posted 23 days ago
    This worked perfectly!  Thank you very much!

    ------------------------------
    Tanya Hammil
    ------------------------------