J.M.,
Yes, you can modify them through the Windows API by writing an ActiveX DLL.
Or More Simply, you can use VBScript and The FileSystemObject and process
the INI file Line by Line and Change the Values this way. Both are fairly
easy, the easiest being a VBScript that would take a command line argument
and process and update the File, Or take Three arguments like:
VBScriptToRun.VBS Arg1, Arg2, Arg3
Where Arg1 would Be the [SECTION] part of the INI file, Arg2 would be the
Left side of the Value under the Key and Arg3 would be the Right side of the
Key or the Actual Value Referenced by the Key.
Ini Sample Section
[Section]
Key=KeyValue
The functions in your Script would update the Keys, Add new Sections if the
section didn't exist, and delete sections if there were no Key Values
remaining, etc.
I have a Class Module in VB already that I used in another program that
would not take a lot of work to Turn it into an ActiveX component, but in
any event, until RB 7.0 comes out, you will still have to use VBScript to
manipulate the Components and send and Retrieve Values to the Component.
Mike
----- Original Message -----
From: "J.M. GRATIAS" <[EMAIL PROTECTED]>
To: "Rbase List server" <[EMAIL PROTECTED]>
Sent: Thursday, April 19, 2001 9:39 AM
Subject: How to call Windows API from RBW ?
>
> Hi all,
>
>
> I need to update a INI file from within my RBW6.5+ app.
>
> This INI file is used by a external Windows software and contain
contextual
> parameters.
>
> According to the author of this external software, those parameters can be
> easily checked and/or changed thru Windows API :
>
> - get informations from a INI file (GetPrivateProfileString )
> - change informations in a INI file (WritePrivateProfileString )
>
> Is this possible to do that from within RBW ?
> How ?
>
> TIA,
>
> J.M. GRATIAS, Logimatique, France
>