[Gambas-user] Question about settings in gambas2.1.9.23
Benoit Minisini
gambas at ...1...
Mon Jan 9 20:24:15 CET 2006
On Monday 09 January 2006 19:57, Charlie Reinl wrote:
> Salut Benoit,
>
> can you or anybody else, explain me what should happen while executing
> the following SUB Main.
>
> SUB Main()
> DIM hSettings AS Settings
> hSettings = NEW Settings("/home/charlie/.myProject.conf")
> PRINT hSettings["PROJECTLANG", "EN"]
> END
>
> I thougth, it is looking at '/home/charlie/.myProject.conf' to find
> "PROJECTLANG"
>
> If found "PROJECTLANG", the value is returned.
>
> If not '/home/charlie/.myProject.conf' will be created if not exists, and
> "PROJECTLANG" is written in with the value "EN" t o the file.
No. You must explicitely assigned something to hSettings["PROJECTLANG"],
otherwise, as nothing is modified in the settings file, nothing is save.
Regards,
--
Benoit Minisini
More information about the User
mailing list