mIRC Home    About    Download    Register    News    Help

Print Thread
Joined: Oct 2003
Posts: 101
R
root66 Offline OP
Vogon poet
OP Offline
Vogon poet
R
Joined: Oct 2003
Posts: 101
Many .ini files look something like the following

Code:
[Favorites]
Favorite=server1:1234
Favorite=server2:2345
Favorite=server3:3456


I propose a flag for /writeini that will cause mirc to append the item to the ini section reguardless of if it exists.

Edit:
I suppose this will also require an additional parameter to $readini since $readini only returns the value of the first item matching the specified name.


Last edited by root66; 19/03/04 10:40 PM.
Joined: Mar 2003
Posts: 1,256
L
Hoopy frood
Offline
Hoopy frood
L
Joined: Mar 2003
Posts: 1,256
That would go against the very principle of inifiles. Inifiles are used to save settings, etc. If you want to save multiple settings, give each setting a different name.

Seeing how your section is named Favorites, you should store your info like this:

[Favorites]
server1=1234
server2=2345
server3=3456

Also, I'm not even sure what you want is possible, since the ini file format is defined by Windows, and not mIRC.

Joined: Oct 2003
Posts: 101
R
root66 Offline OP
Vogon poet
OP Offline
Vogon poet
R
Joined: Oct 2003
Posts: 101
Oh really? Tell that to that developers of Unreal Tournament and the various other games that allow several identically-named items in a .ini section. I am not saying I agree with how they did it, but they did.

Also I would like to note that mIRC returns the number of items, including the extra count for duplicates, if you check the number of items using $ini.


Link Copied to Clipboard