- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-06-2022 09:30 PM
Hi
We need to convert a date to Japanese calendar.
On the client side, dt.toLocaleDateString('ja-JP-u-ca-japanese',{era: 'long'}) works and converts the date to the Japanese calendar without any problem, but
However, the business rule does not work well.
Doesn't it work on the server side?
Please help.
function onChange(control, oldValue, newValue, isLoading) {
if (isLoading)
return;
if (newValue == "") {
g_form.clearValue("end_date_japanese");
return;
}
;
var dt = new Date(newValue);
var japaneseDate = dt.toLocaleDateString('ja-JP-u-ca-japanese',{era: 'long'})
g_form.setValue("end_date_japanese",japaneseDate);
}
Solved! Go to Solution.
- Labels:
-
Scripting and Coding
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-28-2022 12:28 AM
toLocaleDateString does not seem to be supported
Created a custom Japanese calendar conversion script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-28-2022 12:28 AM
toLocaleDateString does not seem to be supported
Created a custom Japanese calendar conversion script

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-28-2022 02:22 AM
Hi
I think you have wrongly marked your own answer as correct!!
Because i said the same thing on my answer too, since "toLocaleDateString" is not supported gave another approach to achieve your requirement.
Kindly mark the applicable answer as Correct & Helpful both such that others can get help.
Thanks,
Sandeep