Auto-Calculate Fiscal Year based on (today) - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Auto-Calculate Fiscal Year based on (today)

Last post 05-08-2012 11:14 AM by Nancy Young. 3 replies.
Page 1 of 1 (4 items)
Sort Posts: Previous Next
  • 05-27-2010 03:08 PM

    Auto-Calculate Fiscal Year based on (today)

    I'm creating a IP 2007 form to help track a list of hardware orders from our many departments.  One of the fields we need is the Fiscal year in which the item was purchased.

     Can I have the Fiscal Year field in my form automatically calculate the fiscal year based on the date give in a field which has (Today) as the default value.  Our Fiscal Year runs from 10/01 - 09/30.  It seems like it wouldn't be too difficult, but i'm just not able to figure it out.

     

    Thanks in advance for your help!

  • 05-27-2010 07:01 PM In reply to

    Re: Auto-Calculate Fiscal Year based on (today)

    Hi Buck_Murdock,

    You may try creating a rule that sets a field's value. The following settings might work for you:

    Action: Set a field's value

    Value: concat(substring(xdDate:Today(), 1, 4), "-", "01", "-", "01")

    Hope it helps.

    Jose Cruz
    Software Test and Support Engineer
    Filed under: , ,
  • 05-27-2010 07:19 PM In reply to

    Re: Auto-Calculate Fiscal Year based on (today)

    I forgot to mention that you should also set the condition on when the rule will be executed. An example is a rule that would only execute when QuarterBegin date is blank AND The expression "04" > substring(xdDate:Today(), 6, 2) AND "01" <= substring(xdDate:Today(), 6, 2)

    Jose Cruz
    Software Test and Support Engineer
    Filed under:
  • 05-08-2012 11:14 AM In reply to

    Re: Auto-Calculate Fiscal Year based on (today)

    I don't like to question gifts, but can you please break this down and explain why this piece of magic works? 

    Thanks,

    nsy

    -Nancy
Page 1 of 1 (4 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.