Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How to add a key to a ini file?
Message
 
 
To
12/11/2002 04:36:09
F Bilo
Bilo Office
Fuyang, China
General information
Forum:
Visual FoxPro
Category:
Windows API functions
Miscellaneous
Thread ID:
00721447
Message ID:
00721568
Views:
9
See, if this message can help:
Re: Moving couple columns in a grid Thread #427567 Message #427627

>I am trying to create a class to access ini file,and get this problem: How to add a key to a section? i use this:
>
>init event:
>*******************************************************************
>Declare WritePrivateProfileSection IN kernel32 As WriPrivSect ;
> STRING lpAppName,;
> STRING lpString,;
> STRING lpFileName
>*******************************************************************
>
>addkey method:
>*******************************************************************
>LPARAMETERS cSection, ckeyname
>
>LOCAL nResult
>nResult = WriPrivSect(cSection, ckeyname ,"", this.inifile)
>Return nResult
>*******************************************************************
>
>Although it will work, but if i try to write a value for this key, always failed.The GetPrivateProfileString API always return this key's name!
>
>How can i do?
If it's not broken, fix it until it is.


My Blog
Previous
Reply
Map
View

Click here to load this message in the networking platform