How To Do Config Files in VB .NET?

Talk about your favorite PC games, Steam and building awesome custom rigs!

Moderator: Moderators

Post Reply
bicostp
Moderator
Posts: 10491
Joined: Mon Mar 07, 2005 5:47 pm
Steam ID: bicostp
Location: Spamalot
Contact:

How To Do Config Files in VB .NET?

Post by bicostp »

For a project I'm working on, I want to put together a menu system that launches automatically when the device is inserted in the PC. (It's built with a 1 gig USB thumbdrive.) Right now I'm using an autostart.inf file and some batch files, but it's a really messy solution that's annoying to work with and has limited practical expandability.

The launcher should be very simple: just an icon that sits in the system tray (by the clock) until you right-click it, when a menu comes up. I've done this before, on a program that kills all IE windows at once. However those functions were hardcoded into the program itself. If i did that here, it would defeat the purpouse of making a launcher in the first place.

Now for the part I'm having trouble with: loading from an external config file. (Registry writes are easier, but I want it to be consistent over multiple computers.) The launcher needs to pull the menu structure from the config file, so it can be expanded cleanly. Sub-menu capabilities would be nice. Hopefully some sort of XML markup can be used to simplify editing, which would be done in Notepad unless making a built-in editor is fairly straightforward. It would also be nice to have the tray icon held in a separate file as well.

All it needs to do is launch external applications with CLI modifiers, and open an HTML help system with the default browser.

What's the easiest way to accomplish this? I'll use another program if necessary, but I'd like to make my own so I don't have to worry about redistribution restrictions. (I want to publish this as an empty skeleton people can build on after it's finished. Might as well, someone might find it useful!)

I'm using Visual Basic .NET 2005 Express.

Thanks!
bicostp
Moderator
Posts: 10491
Joined: Mon Mar 07, 2005 5:47 pm
Steam ID: bicostp
Location: Spamalot
Contact:

Post by bicostp »

Aw, come on. I know at least some of you guys know Visual Basic...
Post Reply