Page 1 of 1

INI vs. DBF

Posted: Fri Mar 24, 2017 8:42 am
by Otto
Hello,
for better file handling I am thinking about changing from INI-files to dbf-files as program setup files.
Could there be a problem with dbf-files using as setup files?

Thanks in advance
Otto

Re: INI vs. DBF

Posted: Fri Mar 24, 2017 10:41 am
by ukoenig
Otto,

I'm using a system.dbf instead reading from a INI
Each user belongs to a record to create his own colors or selected images.
I couldn't notice any problem.

---------- sample -----------------------

FUNCTION LOAD_SYS1()

DBSELECTAREA("SYSTEM")
("SYSTEM")->(DBGOTO(nBenutzer)) // user select

aVal[1] := ("SYSTEM")->nWStyle
aVal[2] := ("SYSTEM")->nWColorF
aVal[3] := ("SYSTEM")->nWColorB
aVal[4] := ("SYSTEM")->nWGradPos
aVal[5] := ("SYSTEM")->lWDirect
aVal[6] := ("SYSTEM")->cWBrush
aVal[7] := ("SYSTEM")->cWImage
aVal[8] := ("SYSTEM")->nWText
aVal[10] := ("SYSTEM")->nWZeit
aVal[11] := ("SYSTEM")->nWDatum
aVal[15] := ("SYSTEM")->cWText
aVal[16] := ("SYSTEM")->lWTextSel
...
...


regards
Uwe :D

Re: INI vs. DBF

Posted: Fri Mar 24, 2017 1:43 pm
by Rick Lipkin
Otto

I have an Enterprise application in State government that is used from different regions through out the State. The application knows nothing about the regional location, so I have no other way of identifying each unique location other than to use a modified .ini . It would be almost pointless to associate a user by location since that user could potentially login from anywhere in the State.

I agree an .ini can be a bit clumsy, but in this case it was the best solution.

Rick Lipkin

Re: INI vs. DBF

Posted: Fri Mar 24, 2017 2:58 pm
by cnavarro
Personally, I have always used in configuration files, the INI files

Re: INI vs. DBF

Posted: Fri Mar 24, 2017 5:33 pm
by Enrico Maria Giordano
Otto wrote:Hello,
for better file handling I am thinking about changing from INI-files to dbf-files as program setup files.
Could there be a problem with dbf-files using as setup files?

Thanks in advance
Otto
The only problem I can see is that is more difficult for the user to make settings. This is not a problem if all settings is done through the application, though.

EMG

Re: INI vs. DBF

Posted: Sun Mar 26, 2017 4:20 pm
by gabo
I think the best way is to use SQLite and you can Encrypted the table
At first you detect if it exists if you can not create it and from your application as Enrico says "all settings is done through the application"
Regards

Re: INI vs. DBF

Posted: Tue Mar 28, 2017 11:27 pm
by cnavarro
I use INIs with values of keys encrypted

Re: INI vs. DBF

Posted: Wed Mar 29, 2017 5:53 am
by Carles
Hi,

Ini files work well for basic application configurations, grid colors, window position, ... which are even easy to manipulate from any editor outside of the application, but in the case of configurations for example referred to user is better in tables.

When you design the maintenance from the tables, at the end you put everything in a parameter table, public and private parameters.