Here is the extract from the source: if (Util.isNull(pattern)) { pattern = MessageResourcesInternal.getMessage( "dbforms.pattern." + getFieldType(), locale); } if (!Util.isNull(pattern)) { if ("short".startsWith(pattern.toLowerCase())) { dateStyle = DateFormat.SHORT; pattern = MessageResourcesInternal.getMessage("dbforms.pattern." + getFieldType() + "." + pattern, locale); } else if ("medium".startsWith(pattern.toLowerCase())) { dateStyle = DateFormat.MEDIUM; pattern = MessageResourcesInternal.getMessage("dbforms.pattern." + getFieldType() + "." + pattern, locale); } else if ("long".startsWith(pattern.toLowerCase())) { dateStyle = DateFormat.LONG; pattern = MessageResourcesInternal.getMessage("dbforms.pattern." + getFieldType() + "." + pattern, locale); } else if ("full".startsWith(pattern.toLowerCase())) { dateStyle = DateFormat.FULL; pattern = MessageResourcesInternal.getMessage("dbforms.pattern." + getFieldType() + "." + pattern, locale); } }
You can to define dbforms.pattern.timestamp dbforms.pattern.date etc. If you use the abbriviations SHORT, MEDIUM, FULL you can define them too: dbforms.pattern.timestamp.short dbforms.pattern.date.full. Dbforms is using public static final int DATE_STYLE_DEFAULT = java.text.DateFormat.MEDIUM; public static final int TIME_STYLE_DEFAULT = java.text.DateFormat.SHORT; As defaults if you do not specify the patterns for each field individually. Could somebody append this to the docs? Shawn????? Thanks Henner > -----Ursprüngliche Nachricht----- > Von: J M Okomba [mailto:[EMAIL PROTECTED] > Gesendet: Freitag, 28. Mai 2004 09:31 > An: 'Henner Kollmann' > Betreff: RE: [dbforms] date pattern in 2.4.rc1 > > > > I haven't seen this new format in the samples I have. Please > send me the resources line. > > > -----Original Message----- > > From: Henner Kollmann [SMTP:[EMAIL PROTECTED] > > Sent: 28 May 2004 08:21 > > To: 'J M Okomba' > > Cc: [EMAIL PROTECTED] > > Subject: AW: [dbforms] date pattern in 2.4.rc1 > > > > > > > > Do I always have to specify the pattern attribute in the > > > <db:dateField /> or there's configuration I am missing out? > > No you must'nt. Date patterns are moved in the resources. > So you can > > change them globally for each type and language > > > DISCLAIMER: This email and any files transmitted with it are > confidential and intended solely for the use of the > recipient. Any disclosure, copying or distribution of all or > part of the information contained herein to or by third > parties is prohibited and may be unlawful. > > In any event the contents herein is without prejudice. > ------------------------------------------------------- This SF.Net email is sponsored by: Oracle 10g Get certified on the hottest thing ever to hit the market... Oracle 10g. Take an Oracle 10g class now, and we'll give you the exam FREE. http://ads.osdn.com/?ad_id149&alloc_id66&op=click _______________________________________________ DbForms Mailing List http://www.wap-force.net/dbforms