Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Source for Timezone table
Message
From
06/01/2009 21:15:23
Cetin Basoz
Engineerica Inc.
Izmir, Turkey
 
 
To
06/01/2009 13:38:44
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows XP SP2
Network:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01371091
Message ID:
01371555
Views:
18
>>>>
>>>>You can get timezones from "HKLM\Software\Microsoft\Windows NT\CurrentVersion\Time Zones" registry entry.
>>>
>>>Cetin
>>>
>>>Do you mind to share your code to list the options (with description and date inf. dif.).. I'm facing more dif. than I hope.. So if you don't mind.. you'll help me a lot..
>>>
>>I will try to strip the part and upload but I need some time. I will do that tonight probably (not so much night for you:)
>
>Cetin.. Here is what I got till now... by now I'm just having some trouble to get the value of 'Index' key of each one and I'm creating a sequential one and it maybe will find any trouble with future program's update (or install) on OS
>
>
>#Define HKEY_LOCAL_MACHINE -2147483646 && BITSET(0,31)+2
>#Define REG_RUN "Software\Microsoft\Windows NT\CurrentVersion\Time Zones"
>
>If  Version(2)=2
>	oReg = Newobject("registry", Home() + "/FFC/Registry.vcx")
>Else
>	oReg = Newobject("registry", "Registry.vcx")
>Endif
>
>lnRegStat = oReg.OpenKey(REG_RUN,HKEY_LOCAL_MACHINE,.T.)
>lnRegValue = 0 && by passing a numeric value, it will assume requested is 32-bit binary
>Dimension aFoxOptions[1,2]
>
>m.nErrNum = oReg.EnumKeyValues(@aFoxOptions)
>lnret=oReg.enumoptions(@aFoxOptions,REG_RUN,HKEY_LOCAL_MACHINE,.T.)
>With This.mycombo2
>	.Clear
>	This.mycombo3.Clear
>	.AddItem(">> none")
>	This.mycombo3.AddItem(">> none")
>	.ListItem(1, 2)=""
>	This.mycombo3.ListItem(1, 2)=""
>	For i = 1 To m.nErrNum
>		lcDisplay=""
>		lcDisplay2=""
>		lcIndex=""
>		lcchave					= REG_RUN+"\"+aFoxOptions[i]
>		lnret 					= oReg.GetRegKey("Display",@lcDisplay, lcchave, HKEY_LOCAL_MACHINE)
>		lnret2 					= oReg.GetRegKey("Std",@lcDisplay2, lcchave, HKEY_LOCAL_MACHINE)
>		lcIndex					= TRANSFORM(i,"@L 9999999")
>		lcDisplay2=ALLTRIM(lcDisplay2)
>		.AddItem(Alltrim(lcDisplay2+" "+lcDisplay))
>		.ListItem(.ListCount, 2)=lcIndex
>		This.mycombo3.AddItem(Alltrim(lcDisplay2+" "+lcDisplay))
>		This.mycombo3.ListItem(This.mycombo3.ListCount, 2)=lcIndex
>	Endfor
>Endwith
>
Sorry to be late but better than never:) Just posted as a reply to previous.
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Previous
Reply
Map
View

Click here to load this message in the networking platform