Rydextillxixdiex Posted June 21, 2008 Posted June 21, 2008 I see people using ini read/write in their scripting and im curious as to what exactly it does. Can somebody give me an example of try to explain it to me. Don't go out of your way as i do not NEED this information for anything im working on, but am just curious. Thanks All. ...will never learn all there is to know about autoit, no worries...i came to the forums :)
James Posted June 21, 2008 Posted June 21, 2008 (edited) INI:The INI file format is a de facto standard for configuration files. INI files are simple text files with a basic structure. They are commonly associated with Microsoft Windows, but are also used on other platforms. The name "INI file" comes from the filename extension usually used, ".INI", that stands for "initialization". Sometimes, files using the INI file format will use a different extension, such as ".CFG", ".conf", or ".TXT".WikipediaI use INI files a lot mainly to save instructions about the program, examples of this can be: startup position, themes, data, URL's. Loads of things can be saved in them!Check out this, which I made, InsideNI|INedisnI it allows you to display data from an INI file in a treeview.Edit: Added link to InsideNI|INedisnI Edited June 21, 2008 by JamesBrooks Blog - Seriously epic web hosting - Twitter - GitHub - Cachet HQ
MHz Posted June 21, 2008 Posted June 21, 2008 I see people using ini read/write in their scripting and im curious as to what exactly it does.Ini files can save information which can be used in another execution of your script. Can somebody give me an example of try to explain it to me.This is probably as basic as I can create. $value = 'value' If Not FileExists('test.ini') Then ; create the ini file and save the key and value IniWrite('test.ini', 'section', 'key', 'value') Else ; ini file exists so show the value of key $return = IniRead('test.ini', 'section', 'key', 'error') MsgBox(0x40000, Default, $return) EndIf The first run will create the ini file and save the section, key and value. Another execution will read the key from within the section and return the value.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now