Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
bhuprakash
Creator II
Creator II

List Box - Week with Start Date and End Date

Hi All,

I want to show the week with their start date and end date in the list box.

Can you please help me to get this done. Below is the format in which i want to show the data.

er.png

1 Solution

Accepted Solutions
martinpohl
Partner - Master
Partner - Master

edit your script:

Week(DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) as ACTIVITYWEEK

to

Week(DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) &': '&weekstart (DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) & ' to '& Weekend(DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) as ACTIVITYWEEK,

regards

View solution in original post

6 Replies
Anil_Babu_Samineni

May be use WeekStart() and WeekEnd() functions ??

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
martinpohl
Partner - Master
Partner - Master

edit your script:

Week(DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) as ACTIVITYWEEK

to

Week(DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) &': '&weekstart (DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) & ' to '& Weekend(DATE(floor([User ActivityCreatedDate]), 'DD-MM-YYYY')) as ACTIVITYWEEK,

regards

zhadrakas
Specialist II
Specialist II

Expression for list box:

='Week' & ACTIVITYWEEK & ': ' & MakeWeekDate(year(today()),ACTIVITYWEEK) & ' to ' & WeekEnd(MakeWeekDate(year(today()),ACTIVITYWEEK))

you should create a yearWeek Field to get the change over years correctly.

bhuprakash
Creator II
Creator II
Author

Hi Martin,

This is showing exactly i want but if I click on Oct month then it is not selecting all the weeks falls in Oct month.

So this causes of showing incorrect data.

bhuprakash
Creator II
Creator II
Author

when i am selecting Oct month then it is not selecting Weeks falls under Oct month.

Please see the attached file.

bhuprakash
Creator II
Creator II
Author

Sorry.. Checked again.. It is working fine.

Thanks a lot everyone.