Getting time based on user time zone in scoped application
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-24-2024 03:29 AM
Hi,
We are looking for a way to get a certain date and time in specific time zone using a script. While there are few methods available in the global application, we can't find any in a scoped application.
For example, the setTimeZone function is not available in scoped application:
var mytime = new GlideDateTime();
mytime.setTimeZone(user.time_zone);
Is there any parallel option in scoped application?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-24-2024 08:22 PM
Hi @Eli Guttman
Can you please let me know the time zone you tried it for ?
Thanks & Regards
Amit Verma
Please mark this response as correct and helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-24-2024 05:30 AM
Hi, I'm looking for solution that is not depended on the logged in user and the session. I need to pull the time zone in a script from a certain user record, not the user who is logged in,
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2025 08:13 AM
@Eli Guttman did you get solutions for the above mentioned case. I need help in implementing the same
