We're a community of 1077K IT Pros here for help, advice, solutions, professional growth and fun. Join us!
1,076,220 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Start New Discussion Reply to this Discussion

selecting an attribute in xml file through variable

The following code line is working fine...

XmlNode sslNode = appHostNode.SelectSingleNode("sites/site[@name = 'www.wow.com']/ftpServer/security/ssl");

Now I want to pass a variable instead of 'www.wow.com'... please guide
how can I do it....

2
Contributors
2
Replies
1 Week
Discussion Span
1 Year Ago
Last Updated
3
Views
Question
Answered
saneeha.nust
Light Poster
46 posts since Jan 2012
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0

Have you tried:

string variableName;

And using this in-line:

'" + variableName + "'
ChrisHunter
Posting Pro
566 posts since Feb 2011
Reputation Points: 104
Solved Threads: 51
Skill Endorsements: 13

Thanks alot... It works...

saneeha.nust
Light Poster
46 posts since Jan 2012
Reputation Points: 10
Solved Threads: 0
Skill Endorsements: 0
Question Answered as of 1 Year Ago by ChrisHunter

This question has already been solved: Start a new discussion instead

Post: Markdown Syntax: Formatting Help
 
You
 
© 2013 DaniWeb® LLC
Page rendered in 0.0726 seconds using 2.65MB