on 04-23-2009 7:02 AM
Hi all,
I have a requirement to format date values in a table for multiple entries to dd/MM/yyyy format in webdynpro java for mutiple line items in that table.
Please help me out with the technique for the same.
Thanks and Regards,
Soumyadeep.
Hi,
here is the code for changing the formatting the date.
Date currentDate = new Date ();
DateFormat df = DateFormat.getDateInstance(DateFormat.SHORT);
String today = df.format(currentDate);
SimpleDateFormat sdfInput = new SimpleDateFormat("dd/mm/yyyy");
SimpleDateFormat sdfOutput = new SimpleDateFormat ("mm/dd/yyyy");
try {
String dateft = sdfOutput.format((Date) sdfInput.parse(df.format(currentDate)));
} catch (ParseException e) {
}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
You can use DateFormat for formatting the dates as per your requirement.
Cheers,
Arafat
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.