- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
Hello Everyone,
gs.getProperty returns the property value as string irrespective of the type of property being accessed. But, if you are in global scope and want to return a property as 'Boolean', you can use GlideProperties.getBoolean() instead. Additionally, there is also a function GlideProperties.getInt() to return the property value as 'int'.
Sample Script :
gs.print(typeof gs.getProperty('glide.invalid_query.returns_no_rows'));
gs.print(typeof GlideProperties.getBoolean('glide.invalid_query.returns_no_rows'));
If my content helped you in anyway, please mark this content as BOOKMARK, SUBSCRIBE & HELPFUL
Best Regards,
Prashant Kumar (LearnIT)
YouTube Channel LearnIT: https://www.youtube.com/@learnitwithprashant
Blog LearnIT: https://medium.com/@LearnITbyPrashant
Prashant Kumar LinkedIn: https://www.linkedin.com/in/learnitbyprashant/
ServiceNow Community Prashant Kumar - https://www.servicenow.com/community/user/viewprofilepage/user-id/19635
- 977 Views
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.