Discussions

 View Only
  • 1.  ToWorkDate() won't work?

    Posted 11-19-2020 10:53
    Edited by Alex Bennett 11-19-2020 11:02
    Hey Everyone,

    I'm having some trouble reformatting my code to get the result of a start date + duration in Numeric to result in a WorkDate, because it seems if it's just the type Date, my duration doesn't include the start date, but If I can convert to WorkDate, then it will include the start date. (For Calendar purposes) According to the QuickBase support center, I can just use: ToWorkDate([Start]) to convert a type Date to WorkDate. However, whenever I attempt this in a Formula - Date Field, I get an error saying expecting date but found workdate... Ok so then if I change it to ToWorkDate(ToDate([Start])), I get an error saying expecting datetime / workdate but got date. The only way i've been able to format this code is to do: ToDate(ToWorkDate([Start])) but then nothing changes in my result for it to include my start date in the duration. For example, If I have a job phase thats showing up in my calendar that is 1 day, the calendar will take the start date and add 1 day, making it 2 days on my calendar, how can I go about this to have the start date included in the count? So that 1 day duration should just be the day that is the start date. What am I doing wrong here??


    Notice Above the 2 durations that say 1 Day...


    Notice how the durations on the calendars are saying 2 days because it is adding "From" the start date, but not including it, so everything has an extra day...

    Any help would be appreciated as I've hit a roadblock with this one!

    Thanks!

    ------------------------------
    Alex Bennett
    ------------------------------


  • 2.  RE: ToWorkDate() won't work?

    Posted 11-19-2020 12:14
    If you need to produce a WorkDate, your formula field needs to be a Formula WorkDate instead of a Formula Date

    ------------------------------
    Blake Harrison
    bharrison@datablender.io
    DataBlender - Quick Base Solution Provider
    Atlanta GA
    404.800.1702 / http://datablender.io/
    ------------------------------



  • 3.  RE: ToWorkDate() won't work?

    Posted 11-19-2020 12:34

    Not seeing an option for Formula - WorkDate.


    ------------------------------
    Alex Bennett
    ------------------------------