Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


VB6 Go to Specific Node

From: "Matthew Shaw" <matted@[----------]-------.---.-->
To: NULL
Date: 5/2/2004 8:06:00 PM
I have several command buttons, each with their own menu (popup). I use an
XML file to set the captions of the command buttons and their corresponding
menus. My XML file is arranged like this:

<places>
    <section>
        <!-- Command button properties-->
        <name></name>
        <description</description>

        <!-- Menu properties -->
        <menu></menu>
        <menu></menu>
    </section>
    <!-- ...and more <sections> -->
</places>

Each button has it's own <section>. I loop through the nodes (for each)

Basically, I want my program to be able to determine what to do when the
user clicks a menu item based on keywords associated with each menu. Thus I
am thinking maybe each <menu> item has an attribute (correct name?)
associated with it, which is the keyword, so each menu item would be like
<menu function="openfile">.

My program can provide the command button's index, which is what number
<section> it got its contents from (ie. the first command button's caption
and corresponding menu would have been from the first <section> tree), and I
can supply the menu's index, (ie. if the user clicks the second item on the
popup menu then we know that it was from the first <menu> item of a
particular <section>.

I am thinking that I loop through a certain number of <section> items
according to the command button number pressed (ie. I press the first
command button so it goes to the first <section> tree). Then, under that
<section> tree, it reads the n'th <place> item's attribute - where n is the
number of the menu clicked (ie. if I click the third menu item, then the
third <place> attribute is read).

I hope I explained myself okay, I'm new to XML and it is kind of hard to
find VB6 XML info. Basically, the end question is, how to do I go to one
specific <section> tree (number is determined by the command button number
pressed) and then read a specific <place> attribute (number is determined by
menu item pressed).

Thanks in advance


Matthew Shaw





transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent