INI class in WTS - Bug ?

Post Reply
Davide
Posts: 190
Joined: Tue Mar 14, 2006 1:59 am
Location: Italy

INI class in WTS - Bug ?

Post by Davide »

In Windows Terminal Service:

Code: Select all

INI oIni FILE GetWinDir()+"\MyIni.ini"
  GET cEntry SECTION "Section" ENTRY "Entry" OF oIni DEFAULT "AAA"
ENDINI
GetWinDir() returns "c:\document and settings\administrator\windows", so MyIni.ini is created here (as it's not already existant). So far so good.

The problem is that IF c:\windows\MyIni.ini already exists, the c:\document and settings\administrator\windows\MyIni.ini file takes the defaults from c:\windows\MyIni.ini instead of the ones coded in the program ("AAA").

Is this supposed to work this way or is it a bug ?

Regards,
Davide
FWH 27 March 2006 - xH 0.99.60 - Bcc
User avatar
Antonio Linares
Site Admin
Posts: 37481
Joined: Thu Oct 06, 2005 5:47 pm
Location: Spain
Contact:

Post by Antonio Linares »

Davide,

It looks as a Windows behavior. If you review the class and the related winapi C file, you will see we don't do anything related
regards, saludos

Antonio Linares
www.fivetechsoft.com
Davide
Posts: 190
Joined: Tue Mar 14, 2006 1:59 am
Location: Italy

Post by Davide »

Antonio,
It looks as a Windows behavior. If you review the class and the related winapi C file, you will see we don't do anything related
yes, I've seen them. No problem once you know it :)
It took some time to me before realizing why my defaults were overwritten. Maybe you could put a note in the doc, so that other users in future will be aware of this behaviour.
Thanks,
Davide.
Post Reply