M
Marc Jennings
Hi there,
I am trying to write a "useful quicklinks" app that populates a
context menu from the contents of an XML file.
My xml file contains the following information...
itemname is what I want to appear in the menu
itemcommand is the application to be called
itemargs is the string containing arguments to be passed to the
command.
I then have a method that calls Process.Start()...
protected void AppLaunch(string applic, string args)
{
Process.Start(applic, args);
}
<y problem is that I have no idea how to create the menu items on the
ContextMenu, and associate the Handler to them.
If anyone can give me a clue, I'd appreciate it.
TIA
Marc.
I am trying to write a "useful quicklinks" app that populates a
context menu from the contents of an XML file.
My xml file contains the following information...
<SysTrayLauncher>
<MenuItem>
<itemname>Explore C Drive</itemname>
<itemcommand>explorer.exe</itemcommand>
<itemargs>c:\</itemargs>
</MenuItem>
<MenuItem>
<itemname>Explore D Drive</itemname>
<itemcommand>explorer.exe</itemcommand>
<itemargs>d:\</itemargs>
</MenuItem>
...etc...
</SysTrayLauncher>
itemname is what I want to appear in the menu
itemcommand is the application to be called
itemargs is the string containing arguments to be passed to the
command.
I then have a method that calls Process.Start()...
protected void AppLaunch(string applic, string args)
{
Process.Start(applic, args);
}
<y problem is that I have no idea how to create the menu items on the
ContextMenu, and associate the Handler to them.
If anyone can give me a clue, I'd appreciate it.
TIA
Marc.