Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Adding and Parsing custom app.config files.

Posted on 2007-03-31
1
Medium Priority
?
203 Views
Last Modified: 2013-11-25
I am looking to create a vb.net service that runs applications (i.e. notepad, ie, etc) when it is stoped or started.  I want the application paths to be configurable via xml file (like app.config).

I can not figure out how to place the nodes in app.config and then parse them out in the OnStart sub.

My thoughts on the xml section are as follows

<OnStart>
 <app name="..." path="..." ExecOrder="1" />
 <app name="..." path="..." ExecOrder="2" />
 <app name="..." path="..." ExecOrder="3" />
</OnStart>
<OnStop>
 <app name="..." path="..." ExecOrder="1" />
 <app name="..." path="..." ExecOrder="2" />
 <app name="..." path="..." ExecOrder="3" />
</OnStop>


 Protected Overrides Sub OnStart(ByVal args() As String)
 
  For Each Node in OnStart
        System.Diagnostics.Process.Start("Path")
  Next

 End Sub
0
Comment
Question by:makman111
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 19

Accepted Solution

by:
Rimvis earned 2000 total points
ID: 18834894
I suggest you place your settings in separate XML file.
Take a look here:
http://www.codeproject.com/vb/net/parsefilecode.asp
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

What do responsible coders do? They don't take detrimental shortcuts. They do take reasonable security precautions, create important automation, implement sufficient logging, fix things they break, and care about users.
The SignAloud Glove is capable of translating American Sign Language signs into text and audio.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Six Sigma Control Plans
Suggested Courses

618 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question