Click here to Skip to main content
15,893,161 members
Home / Discussions / C#
   

C#

 
GeneralRe: How do i make an XML document only read/writeable by my ASP.NET app? Pin
Dan Neely15-Feb-06 7:10
Dan Neely15-Feb-06 7:10 
GeneralRe: How do i make an XML document only read/writeable by my ASP.NET app? Pin
J4amieC15-Feb-06 21:58
J4amieC15-Feb-06 21:58 
QuestionCutting out a triangular chunk in DirectX Pin
melanieab15-Feb-06 4:45
melanieab15-Feb-06 4:45 
QuestionLocalization issues with custom controls Pin
User 190837815-Feb-06 3:44
User 190837815-Feb-06 3:44 
AnswerRe: Localization issues with custom controls Pin
Andy Moore15-Feb-06 5:17
Andy Moore15-Feb-06 5:17 
GeneralRe: Localization issues with custom controls Pin
User 190837815-Feb-06 5:39
User 190837815-Feb-06 5:39 
AnswerRe: Localization issues with custom controls Pin
Andy Moore15-Feb-06 5:25
Andy Moore15-Feb-06 5:25 
Questionhow to represent xml document on treeviewer using c# Pin
panter_rose15-Feb-06 3:39
panter_rose15-Feb-06 3:39 
i use this code to represente xml document oon treeViewer
but the attributes don't apprae in treeViewer
can you help me
<br />
try<br />
{<br />
    // Create a DOM Document and load the XML data into it.<br />
    XmlDocument dom = new XmlDocument();<br />
    dom.Load(textBox1.Text);<br />
<br />
    // Initialize the TreeView control.<br />
    treeView1.Nodes.Clear();<br />
    treeView1.Nodes.Add(new TreeNode(dom.DocumentElement.Name));<br />
    TreeNode tNode = new TreeNode();<br />
    tNode = treeView1.Nodes[ 0 ];<br />
<br />
    // Populate the TreeView with the DOM nodes.<br />
    AddNode(dom.DocumentElement, tNode);<br />
    treeView1.ExpandAll();<br />
}<br />
catch(XmlException xmlEx)<br />
{<br />
    MessageBox.Show(xmlEx.Message);<br />
}<br />
catch(Exception ex)<br />
{<br />
    MessageBox.Show(ex.Message);<br />
}<br />
 <br />
<br />
<br />
		<br />
private void AddNode(XmlNode inXmlNode, TreeNode inTreeNode)<br />
{<br />
 XmlNode xNode;<br />
 TreeNode tNode;<br />
 XmlNodeList nodeList;<br />
 int i;<br />
<br />
 // Loop through the XML nodes until the leaf is reached.<br />
 // Add the nodes to the TreeView during the looping process.<br />
 if (inXmlNode.HasChildNodes)<br />
 {<br />
    nodeList = inXmlNode.ChildNodes;<br />
    for(i = 0; i<=nodeList.Count - 1; i++)<br />
    {<br />
       xNode = inXmlNode.ChildNodes[ i ];<br />
       inTreeNode.Nodes.Add(new TreeNode(xNode.Name));<br />
       tNode = inTreeNode.Nodes[ i ];<br />
       AddNode(xNode, tNode);<br />
    }<br />
 }<br />
 else<br />
 {<br />
    // Here you need to pull the data from the XmlNode based on the<br />
    // type of node, whether attribute values are required, and so forth.<br />
    inTreeNode.Text = (inXmlNode.OuterXml).Trim();<br />
 }<br />
}<br />
 <br />

AnswerRe: how to represent xml document on treeviewer using c# Pin
PicklesTheClown15-Feb-06 6:18
PicklesTheClown15-Feb-06 6:18 
GeneralRe: how to represent xml document on treeviewer using c# Pin
panter_rose17-Feb-06 21:40
panter_rose17-Feb-06 21:40 
QuestionHelp Me! Pin
am2h15-Feb-06 3:08
am2h15-Feb-06 3:08 
AnswerRe: Help Me! Pin
J4amieC15-Feb-06 4:45
J4amieC15-Feb-06 4:45 
QuestionWin32 API Problems Pin
snouto15-Feb-06 2:13
snouto15-Feb-06 2:13 
AnswerRe: Win32 API Problems Pin
Dan Neely15-Feb-06 2:16
Dan Neely15-Feb-06 2:16 
QuestionHttp basic authentication problem Pin
khaasJ15-Feb-06 2:12
khaasJ15-Feb-06 2:12 
QuestionWhere can i find MSR.LST.Net.Rtp.dll? Pin
Divyang Mithaiwala15-Feb-06 1:28
Divyang Mithaiwala15-Feb-06 1:28 
AnswerRe: Where can i find MSR.LST.Net.Rtp.dll? Pin
Dave Kreskowiak15-Feb-06 14:38
mveDave Kreskowiak15-Feb-06 14:38 
GeneralRe: Where can i find MSR.LST.Net.Rtp.dll? Pin
KarstenK15-May-14 4:40
mveKarstenK15-May-14 4:40 
GeneralRe: Where can i find MSR.LST.Net.Rtp.dll? Pin
Dave Kreskowiak15-May-14 9:32
mveDave Kreskowiak15-May-14 9:32 
Questioncar plate recognition Pin
jianloong15-Feb-06 1:14
jianloong15-Feb-06 1:14 
AnswerRe: car plate recognition Pin
James Gupta15-Feb-06 1:55
professionalJames Gupta15-Feb-06 1:55 
AnswerRe: car plate recognition Pin
Divyang Mithaiwala15-Feb-06 2:08
Divyang Mithaiwala15-Feb-06 2:08 
GeneralRe: car plate recognition Pin
jianloong15-Feb-06 2:51
jianloong15-Feb-06 2:51 
GeneralRe: car plate recognition Pin
LighthouseJ15-Feb-06 7:51
LighthouseJ15-Feb-06 7:51 
GeneralRe: car plate recognition Pin
James Gupta15-Feb-06 12:23
professionalJames Gupta15-Feb-06 12:23 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.