This is a list of functions supported by the Softwing.LocaleFormatter object. At this time, there are no properties. Notice that the functions are not listed in any particular order and the documentation isn't very "strong", however, most of the functions should be self-explaining. If not, take a look at the sample ASP file that comes with the component.
If you have any questions, then please contact Christoph Wille, MVP for Active Server Pages. The most recent version of this component can always be found at http://www.softwing.com/iisdev/localeformatter/.
Formats dates according to the locale settings.
Formats time according to the locale settings.
Formats date and time into a single string using default settings for the locale.
Returns the name of the month, either short (abbreviated) or at full length in the correct language for the locale.
Gets the name of the weekday, either abbreviated (short, three-character) or long (full month name). The last argument takes the first day of week, 0 being locale default, 1 for Sunday up to 7 for Saturday. The functionality is the same as the VBScript function.
Formats currency values according to the locale settings.
Formats numbers according to the locale settings (including the number of digits).
Formats a date according to a format picture string you supply. Letter case does matter. Characters enclosed in single quotation marks (') will appear unchanged in the formatted string (spaces will also show up in the output).
Picture | Meaning |
---|---|
d | Day of month as digits with no leading zero for single-digit days. |
dd | Day of month as digits with leading zero for single-digit days. |
ddd | Day of week as a three-letter abbreviation. |
dddd | Day of week as its full name. |
M | Month as digits with no leading zero for single-digit months. |
MM | Month as digits with leading zero for single-digit months. |
MMM | Month as a three-letter abbreviation. |
MMMM | Month as its full name |
y | Year as last two digits, but with no leading zero for years less than 10. |
yy | Year as last two digits, but with leading zero for years less than 10. |
yyyy | Year represented by full four digits. |
gg | Period/era string. |
For example, to get the date string "Wed, Nov 18 98" use the following picture string: "ddd',' MMM dd yy"
Formats a time according to a format picture string you supply. Letter case does matter. Characters enclosed in single quotation marks (') will appear unchanged in the formatted string (spaces will also show up in the output).
Picture | Meaning |
---|---|
h | Hours with no leading zero for single-digit hours; 12-hour clock |
hh | Hours with leading zero for single-digit hours; 12-hour clock |
H | Hours with no leading zero for single-digit hours; 24-hour clock |
HH | Hours with leading zero for single-digit hours; 24-hour clock |
m | Minutes with no leading zero for single-digit minutes |
mm | Minutes with leading zero for single-digit minutes |
s | Seconds with no leading zero for single-digit seconds |
ss | Seconds with leading zero for single-digit seconds |
t | One character time marker string, such as A or P |
tt | Multicharacter time marker string, such as AM or PM |
For example, to get the time string "01:12:20 AM" use the following picture string: "hh':'mm':'ss tt"