Avatar of AlexPonnath
AlexPonnath
Flag for United States of America asked on

Vb.net XML Read all nodes and

I am looking for some code, that will read an XML document including all Child Nodes no matter how deep as well
as the attributes. i have some code that does that but only goes 1 child deep and i am looking for a more dynamic
code which will go as deep as required. As an output i am looking for something like. below is an XML sample

<OrigParty type="PBXPartyType" subscribergroup="Subscribers in LATA 738" billingtype="flat rate" privacy="false" cpc="normal" ani-ii="00">
				<TrunkGroup type="sip">
					<TrunkGroupId>65535</TrunkGroupId>
					<TrunkMemberId>0</TrunkMemberId>
				</TrunkGroup>
				<SubscriberAddr type="e164">+12095551122</SubscriberAddr>
				<CallingPartyAddr type="e164">+12095551122</CallingPartyAddr>
				<ChargeAddr type="e164">+12095551122</ChargeAddr>
				<SIPCallId>32822942-575B11E6-95DAB3D4-69DB7200@192.168.233.30</SIPCallId>
			</OrigParty>

Open in new window

Visual Basic.NETXML

Avatar of undefined
Last Comment
Fernando Soto

8/22/2022 - Mon
SOLUTION
Fernando Soto

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
AlexPonnath

ASKER
is there any way to print all parent Nodes  before the node.LocalNmae ?

i would like to have a output where names would be like

RootNode
RootNode-1StChild
RootNode-1stChild-SecondChild
Fernando Soto

That was not stated in the original question. Please show exactly what you want to receive back from the XML document. If a class for each element and what properties you want in the class. If just a string for each node what exactly do you want in it. Please be specific.
ASKER CERTIFIED SOLUTION
Fernando Soto

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck