| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | profile |
Tom Brown wrote in a message to Jonathan de Boyne Pollar: TB> 1) I like to use an environment variable instead of an INI TB> entry to point to my .INI file. This way, I can install my TB> applications by simply copying files and editing the TB> config.sys. I have a much better suggestion. Have your EXE file determine which directory it is running from, and use a default INI file there. This will be sufficient for 95% of the cases your program is used. For the exceptions, allow an environment variable or command line switch to override the default. You must be careful to provide for cases where the EXE is located on a network, and in which users either will need different INI files or will not have write permission for the directory in which the EXE is located. TB> 2) I much prefer to use text mode .INI files for easier TB> editing. I agree with this. TB> The thing that has been bugging me about point 1 is that it TB> requires me to boot my PC. I'm getting to the point where I TB> get really annoyed whenever I have to boot my PC. The user TB> INI file would allow me to solve this problem, but feel TB> weird about messing with it. My suggestion fixes this 95% of the time if you use an environment variable override, or 100% of the time if you use a command line switch override. TB> My problem with point 2 is that the code I wrote to handle TB> this (3 C++ classes: Profile, ProfileSection, and TB> ProfileEntry) really bloat out my code. The first 2 classes TB> inherit from ISequence, which makes them fairly expensive in TB> terms of code size. The OS/2 API adds roughly nothing to my TB> executible size and probably executes faster. BTW, I would TB> be happy to share this code with anyone who is interested. Look at lex and yacc for generic techniques. The OS/2 API code resides in system DLLs, while your own functions obviously have to reside in your own modules. This is an inevitable trade-off, but I can't see your own functions being very large. TB> It would be great if there were standards, or at least TB> prefered method outlining this sort of thing in detail by a TB> source of authority. Well, you can quote me. -- Mike ---* Origin: N1BEE BBS +1 401 944 8498 V.34/V.FC/V.32bis/HST16.8 (1:323/107) SEEN-BY: 50/99 270/101 620/243 711/401 409 410 413 430 808 934 955 712/407 SEEN-BY: 712/515 517 628 713/888 800/1 @PATH: 323/107 396/1 270/101 712/515 711/808 934 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.