Skip to main content
Announcements
Global Transformation Awards! Applications are now open. Submit Entry
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

change listbox using calendar

Hi,

i have:

1. Listbox Object with dates

2. Calendar Object for choose 1-st date in period

3. Calendar Object for choose last date in period

I want choose 1-st and last date in period. When i choose period i want to see in Listbox Object only dates in period with condition:

(date >= 1-st date in period and date <= last date in period)

and they must be already selected

please help

1 Solution

Accepted Solutions
johnw
Champion III
Champion III

Your actions select all possible dates.  Just because your list box doesn't display them doesn't mean they aren't selected, which you could see by making a date list box.  Instead of selecting possible, you need to select with a search string like this:

='>=$(=date(nach_p,'YYYYMMDD'))<=$(=date(konec_p,'YYYYMMDD'))'

You could remove the 'YYYYMMDD' codes if you formatted your dates consistently with the SET DateFormat in the script.  You're not restricted to only the YYYYMMDD format here.

View solution in original post

8 Replies
thomas_skariah
Creator III
Creator III

Hi,

Is this date in YYYYDDMM?

Regards,

Tom

Gysbert_Wassenaar

See attached qvw. If you explicitly format the dates as dates in YYYYMMDD format it works.


talk is cheap, supply exceeds demand
Not applicable
Author

Hi, Tom

yes

Not applicable
Author

Hi,

this is what i need!

 

And is it possible to set selected all dates in this listbox?

Gysbert_Wassenaar

Yes, in the document properties screen you can add triggers for the OnInput actions of the variables. If you set the action to Select Possible for field date then if you pick another date in one of the calendars the selection will change too.


talk is cheap, supply exceeds demand
Not applicable
Author

it is working, but my table does't changing.

listbox does changing, but table Count (otvetstv) not.

why? if i manualy select some value in listbox, table also changing.

johnw
Champion III
Champion III

Your actions select all possible dates.  Just because your list box doesn't display them doesn't mean they aren't selected, which you could see by making a date list box.  Instead of selecting possible, you need to select with a search string like this:

='>=$(=date(nach_p,'YYYYMMDD'))<=$(=date(konec_p,'YYYYMMDD'))'

You could remove the 'YYYYMMDD' codes if you formatted your dates consistently with the SET DateFormat in the script.  You're not restricted to only the YYYYMMDD format here.

Not applicable
Author

Thank you, John!

Now it is work perfectly!