Troubleshooting date format issues in reports and notifications
Who is this article for?Users experiencing date format issues with report templates and notification emails.
Application server access is required to resolve the issue.
Users may find that report templates and notification emails are populated with dates in the MM/DD/YYYY format, even if the server and client PC locales are set to a region using a different format.
This article explains why this happens and how to resolve the problem.
1. Issue
You may find that report templates or notification emails show dates in the MM/DD/YYYY, even if your server settings are set to a region using a different format.
The processes that populate document templates and create email notifications run on the application server, and the services responsible for them use their own region settings to interpret the date.
If a server is set to US region settings, and is then changed to some other region after the Internal Audit services have been installed and run, then the services will continue to use the MM/DD/YYYY format settings.
This is because the date format is specified in the service user's profile, and this didn't get updated when the server region was changed.
2. Solution
To resolve the issue, change the short date setting in the service user profiles to be DD/MM/YYYY. One way to do this is suggested below.
2.1 Look up the SIDs for the service users
If you are using domain users for the Robot service and Pentana application pools, and you are using the standard names, you can look up their SIDs using PowerShell.
Import-Module ActiveDirectory
Get-AdUser -Identity PentanaService | Select Name, SID, UserPrincipalName
Get-AdUser -Identity PentanaRobot | Select Name, SID, UserPrincipalName
2.2 Edit sShortDate in the affected user profiles
In Regedit, go to HKEY_USERS and find the list of user profiles.
For the two matching profiles:
- Go to \Control Panel\International.
- Locate the entry for sShortDate.
- Change the value to dd/MM/yyyy.
In the example screen shot above, the Robot service user's SID is S-1-5-21-1564808984-3684834122-2464908622-1107. To make the change:
- Open Regedit.
- Go to HKEY_USERS\S-1-5-21-1564808984-3684834122-2464908622-1107\Control Panel\International.
- Edit the sShortDate entry to dd/MM/yyyy.
Make the same change for the PentanaService user (in this example, that would be S-1-5-21-1564808984-3684834122-2464908622-1106).
2.3 You might find there is no entry at HKEY_USERS for PentanaService
If you find that there is no matching entry for PentanaService in the registry, this means the PentanaService user is inheriting its settings from the LocalSystem account.
In this instance, you should make the change for user S-1-5-18:
2.4 Reboot
After making the changes, reboot the application server.