You need to sign in to do that
Don't have an account?
John L.
Visualforce, JavaScript, and localization
I've a Visualforce code snippet that retrieves the week number of a Apex timestamp attribute:
However, the timestamp is GMT, not localized. I'm GMT+5, so I get the wrong results after 7pm Saturdays.
The documentation suggests using $A.localizationService.formatDate(...), but placing it around the 0, or around the param value attribute don't pass the editor syntax checks.
Thanks in advance for any clarity you can provide.
<apex:outputText id="currweek" style=" align : center ; " value="W{0,date,w}"> <apex:param value="{!tk.StopTime__c}"/> </apex:outputText>
However, the timestamp is GMT, not localized. I'm GMT+5, so I get the wrong results after 7pm Saturdays.
The documentation suggests using $A.localizationService.formatDate(...), but placing it around the 0, or around the param value attribute don't pass the editor syntax checks.
Thanks in advance for any clarity you can provide.
Please check the stack Exchange link for the same.
https://salesforce.stackexchange.com/questions/266502/localizationservice-formatdatetime-method-is-not-displaying-correct-time-in-euro
Related Link
https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/js_cb_format_dates.htm
I hope your question is answered above.
Please mark it as Best Answer if the above information was helpful.
Thanks.