Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
I have a developed the Qlik sense dashboard where I am showing the last refreshed datetime using Reloadtime().
The problem is that it is showing time as per the Qlik Sense server location but my requirement is it should show datetime as per the location of the user. For example if the user is in India then datetime should be in IST, if the user is in London then datetime should be in GMT etc. etc.
I tried using converttolocaltime() but I think, I need to specify the timezone and my users are in more than one timezone.
@Manish
I found another way that may work for you.
It's not using local time but this will tell you how many minutes ago that the last reload took place.
So this way, if that's all you need to know how many minutes ago the the last reload took place, this should be a good workaround.
=(localtime() - Reloadtime() ) *1440
where 1440 are the number of minutes in a day.
Change the format pattern to #,##0 so to remove the decimal points.
So this way you have 'how many minutes ago' as to when the last reload took place, regardless of which time zone your end users are viewing from.
Hope this works for you...
Kind regards.
Try this formula using UTC time. Make sure to ensure the GMT time value for your time zone.
For US Canada Pacific it is as you see it below:
ConvertToLocalTime(UTC(), 'GMT-08:00')
Result: Taken at the time indicated in the image below:
Kind regards...
Hi @Frank_S
Many thanks for your reply. Just a quick one, For my time zone which is IST below is giving the correct local time but will it also give the correct local time say for the user who is in North America?
ConvertToLocalTime(UTC(),'GMT+05:30')
I just need that whenever users open the dashboard on Hub from their respective region they should see Last refresh date time as per their local time . NA user should see NA local time , India user should see India local time and so on and so forth.
Can this be done?
The backend qlik engines are in the QlikCloud and as such use UTC.
As as suggestion, you may wish to add additional text and image objects as I've shown above (as an example of just one timezone) that contain different time zones that you wish to show. (perhaps 3 objects: 1 for IST, 1 for AEST, 1 for CET).
There is no known built syntax/feature for conditionally recognizing the locations/timezone in which the user is accessing the Qlik Cloud tenant from.
Please write a feature request here to submit that idea as a feature request.
Kind regards...
Any possibility if you can identify location based on logged in user by using OSUser(), somehow if you can build associated location data for logged in users, it might help to build the required logic. Just giving some thought, might not work in your situation...
@Manish
I found another way that may work for you.
It's not using local time but this will tell you how many minutes ago that the last reload took place.
So this way, if that's all you need to know how many minutes ago the the last reload took place, this should be a good workaround.
=(localtime() - Reloadtime() ) *1440
where 1440 are the number of minutes in a day.
Change the format pattern to #,##0 so to remove the decimal points.
So this way you have 'how many minutes ago' as to when the last reload took place, regardless of which time zone your end users are viewing from.
Hope this works for you...
Kind regards.