Click here to Skip to main content
Licence 
First Posted 6 Aug 2006
Views 14,052
Bookmarked 16 times

How to manage the xml files

By | 6 Aug 2006 | Article
You can use this class to manage the xml files
  • <A href="XmlControl/XmlControl_src.zip"></A><A href="XmlControl/XmlControl_src.zip"></A><A href="http://www.codeproject.com/useritems/XmlControl/20060805.zip">Download source files - 9.66 Kb</A> 

Introduction

I found use the .net framework to manage the xml is very dificult. but the .net framework is had a lot of functions. This XmlControl's function is less, but I think that's enough to manage the xml files in commonly.

If you want to use this control to manage an exit xml file, you can use folow example to use.

<BR>XmlControl fileCon=new XmlControl("filePath");

If you want to create an new xml file, you can use this

XmlControl fileCon=new XmlControl();

You must set the XmlControl's RootNode like this

fileCon.RootNode.Name="example";

You can't to save the file that you can't set the RootNode's name.

You can use the XmlControl.Elements.Add() method to add an xml node, like this

<BR>XmlElement elem=new XmlElement(); <BR>elem.Name="example"; <BR>elem.Value="example"; <BR>fileCon.Elements.Add(example);

If you can't understand, you can use the Email to connect me. Because my english is poor so ......  ^_^

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

zhengxiaobao

Web Developer

China China

Member

Deverloper

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board. (secure sign-in)
 
Search this forum  
 FAQ
    Noise  Layout  Per page   
  Refresh
Generalvote of 1 Pinmemberrootjumper10:06 1 Sep '09  
GeneralThanks Pinmembernorm .net23:22 6 Aug '06  
GeneralRe: Thanks PinmemberRobert Rohde3:29 7 Aug '06  

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

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

Permalink | Advertise | Privacy | Mobile
Web03 | 2.5.120517.1 | Last Updated 7 Aug 2006
Article Copyright 2006 by zhengxiaobao
Everything else Copyright © CodeProject, 1999-2012
Terms of Use
Layout: fixed | fluid