Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-25-2021 01:15 PM
That's different. In which case, I would eliminate the commas and format accordingly. Here is proof that you can run in Scripts - Background:
var oString = '20,210,526';
var nString = oString.replace(/,/g, "");
gs.info(nString);
var yyyy = nString.slice(0,4);
var mm = nString.slice(4,6);
var dd = nString.slice(6,8);
gs.info(yyyy);
gs.info(mm);
gs.info(dd);
var gd = new GlideDate();
gd.setDate(yyyy + '-' + mm + '-' + dd);
gs.info(gd);