Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Dynamically Change Start date and End date

Hello,

I have a requirement. I have two sets for Dates and a baseLine Type. If the user selected Base line type as 'Average 12 months' and a start date and End Date, then my Baseline Start Date and Baseline End Date should automatically change.

Below example:

Start Date : 2/1/2104

End Date: 3/1/2014

Baseline Type: Average 12 months

Baseline Start Date: start date minus 12 months

Baseline End Date: Start Date

Any help?

Thanks is adance

1 Solution

Accepted Solutions
Not applicable
Author

Let me know if you like it.

regards

Darek

View solution in original post

8 Replies
whiteline
Master II
Master II

Hi.

If you want just subtract 12 months use AddMonths function.

Not applicable
Author

Padmaja,

for me it looks like you may need use variables to store Baseline Start and Baseline End dates.

You may set those variables using event triggers (menu Settings/Document Properties/Triggers).

There are many possible actions to add. Set Variable is in External group. When you choose it, you have to define your variable and define expression, which calculates value for your variable.

Let us know if you need more help.

regards

Darek

Not applicable
Author

Thanks Darek. Yes, I can create  variables and use triggers...but the issue is I have more than one baseline type like 'Average of 3 months'...

whenever, the user selects a baseline type,Start Date and End Date the Baseline Start Date and Baseline End Date has to change (depending on 3 months or 12 months or previous week).

I have to use Baseline Start Date in different calculations in my charts.

Thanks

Not applicable
Author

Padmaja,

you may use all expressions dynamically, according to "baseline type" selected by user.

There may be expressions (or expression parts) used to calculate your KPI's, variables or searching values in other fields to trigger selection.

Do you think some example will help you?

regards

Darek

Not applicable
Author

Darek,

Yes,  example would really help me.

My question is when i set trigger for a variable to calculate 12 or 3 months..which expression should i define and how do i tie it back to the baseline type selection by user.

Thanks

Not applicable
Author

Let me know if you like it.

regards

Darek

Not applicable
Author

Thanks Darek. It worked. This is what I was looking for.

Fadi_Chammas
Contributor
Contributor

can I please have the qvf file for this?