You are hereFBconfig - Cross Platform configuration for FreeBASIC
FBconfig - Cross Platform configuration for FreeBASIC
Fbconfig is a small library that packs a big punch. Never worry about distributing a configuration file again, because with fbconfig it is generated with the first program run and stored in the "correct" place for each platform. The on disk format is plain-text xml, easy to modify by hand if your user desires. Due to the simple api with fbconfig you can get up and running in no time, and if you need to do the advanced you can access the raw xml but this shouldn't be needed in 99% of cases.
License: New BSD style (like the Extended Library)
Project Links:
- Downloads: http://code.google.com/p/libfbconfig/downloads/list
- Mercurial Repository: http://code.google.com/p/libfbconfig/source/browse/
- Wiki: http://code.google.com/p/libfbconfig/w/list
- Forum: http://mud.owlbox.net/forums/projects/fbconfig
Simple Example:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | #define NO_EXT 1 'only needed if you're not using the Extended Library as well #include "fbconfig.bi" config.set_app_name( "AwsmApp" ) config.load() var user = config.get_string("username","Bob") var userid = config.get_integer("username",1) 'each "name" can have 1 string, 1 integer or double 'and 1 bool attached, but if you do this the string must come first. print using "Hello, &. You are user number ###."; user, userid config.save() 'now try modifying values in the config file, see wiki for location for your platform. |
