Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

getLocale

Hello there

Please, help me how to get current language on IE, not Windows itself, from WebDynpro App .

The best would be to get "Date" in form of template something like this: MM-dd-yyyy, in accordance with the current language in IE.

Message was edited by:

Stefan Stefanov

Former Member
Former Member replied

Hi,

You can do something like:

IWDClientUser usr = WDClientUser.getLoggedInClientUser();
		
Date currDate = new Date(System.currentTimeMillis());
		
SimpleDateFormat dFormat = new SimpleDateFormat("MM-dd-yyyy",usr.getLocale());

dFormat.format(currDate);

Regards,

Satyajit.

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question