|
-
Dec 16th, 1999, 11:41 AM
#1
Thread Starter
Lively Member
Hi,
Who knows how to read the "Short date style" & "Date seperator" from the regional settings ?? And Who knows how to change those value's ??
OS = 95, 98 & NT
R@emdonck
-
Dec 16th, 1999, 01:42 PM
#2
I'm not sure if it's the easiest way to do what you're trying to do but in the past I have used 2 API calls to get the values from the registry. To read the values use the RegQueryValueEx API and ato edit them use the RegSetValueEx API.
The registry values that you are interested in are: HKEY_CURRENT_USER\Control Panel\International\sDate
and
HKEY_CURRENT_USER\Control Panel\International\sShortDate
-
Dec 16th, 1999, 05:29 PM
#3
Addicted Member
You can use Format() function
MyStr = Format(Time, "Short Time")
MyStr = Format(Date, "Short Date")
And for the Date separator:
Function DateSeparator() As String
Dim s As String * 1
s = Right(Date, 3)
DateSeparator = s
End Function
Usage: MsgBox "Date separator is " & DateSeparator
------------------
smalig
[email protected]
http://vbcode.webhostme.com/
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|