| Forum List • Thread List • Refresh • New Topic • Search • Previous • Next 1 | 1. Problem using wxFileConfig #3892 Posted by: 2004-04-22 20:24:16 | Well, first, sorry for my horrible english... I have one problem. Well, i have a lot of!! ;)
I was reading this post
http://g.yi.org/forum/read.php?13,3119,3122
becouse i have the same problem. Finally, i could try the wxIniFile class correctly but it is incomplete. Then, i try the wxFileConfig, witch is multiplataform compatible (the other no). But i don't know how to initialize them!! I haven't any error but the constructor never make the my config file. Can anybody give me a small example?
Thank you :) | 2. Anybody? #3904 Posted by: 2004-04-23 20:19:24 | Anybody can give me a small sample? Only constructor... | 3. Re: Problem using wxFileConfig #3905 | 1 day passed and you did not even go to look in the sources how the constructor works? :p
wxFileConfig(const wxString& appName = wxEmptyString, const wxString& vendorName = wxEmptyString, const wxString& localFilename = wxEmptyString, const wxString& globalFilename = wxEmptyString, long style = wxCONFIG_USE_LOCAL_FILE | wxCONFIG_USE_GLOBAL_FILE, wxMBConv& conv = wxConvUTF8);
Meow~ | 4. Re: Problem using wxFileConfig #3925 Posted by: 2004-04-25 22:39:48 | Oh, sorry... I have not explained well. Yes, i looked the sources and the constructor, but it not works. I try with a lot of possibilities but nome works correctly. The constructor don't make the file on my HD and i can't work with the object. I do not know that happens. If you can give me an small sample of the constructor... I only want to know how to make a local config file (in the app directory).
Sorry for my form of expressing. Thank you | 5. Re: Problem using wxFileConfig #4105 Posted by: 2004-05-13 18:41:01 | wxFileConfig *ini = NULL; //the third parameter is a local filename, make sure // not to use the wrong slash '\' use only '/' //you can skip the fourth parameter as it will be set to this automaticly anyway ini = new wxFileConfig("","","c:/myapp/config.ini","",wxCONFIG_USE_LOCAL_FILE);
ini->Write("key","value");
//enjoy | 6. Re: Problem using wxFileConfig #4110 Posted by: chot 2004-05-14 01:14:38 | i have had some other problems with the wxFileConfig (not saving correctly) so i would recomend you to use xml, if you are going to save anything that is a bit more complicated than 4 strings and an int. i use and like libxml2 | Forum List • Thread List • Refresh • New Topic • Search • Previous • Next 1 |
|
|