Jump to content


Photo

how to read an xml file from "My Documents"

- - - - -

  • Please log in to reply
2 replies to this topic

#1
sriram

sriram

    Newbie

  • Members
  • Pip
  • 1 posts
  • Devices:imate jasjar
I'm a newbie to programing in windows mobile 5 using visual c#. What I'm trying to do is build an app that reads a xml file from "My Documents" and changes the data around to display it. How do i get my program to read the xml file? ;)

  • 0

#2
ddmf

ddmf

    Regular

  • Members
  • PipPip
  • 88 posts
  • Location:Dundee
  • Interests:stuff!
  • Devices:MDA Vario II

I'm a newbie to programing in windows mobile 5 using visual c#. What I'm trying to do is build an app that reads a xml file from "My Documents" and changes the data around to display it. How do i get my program to read the xml file? ;)


Have a look at: http://support.microsoft.com/kb/307548

Also, rather than hard code the path, use Environment.GetFolderPath(Environment.SpecialFolder.Personal) which will return the path of the My Documents folder!

  • 0
Developing: Onsite Consultant Invoicing system... Products and Customers on your phone, get them to sign, add notes - sends email to special email address. Invoice server reads email, creates sales order & emails customer. After 3 weeks or >£ amount invoices can be autocreated and emailed...

Mobile History: star-tac 5200 -> pf768 -> t14 -> 3210 -> 8210 -> 8310 -> 7650 -> 7250 -> t610 -> mpx200 -> c500 -> mda compact -> mda vario -> mda vario 2 -> mda varia 3 / nokia n95 -> ???

#3
kalkie2007

kalkie2007

    Newbie

  • Members
  • Pip
  • 2 posts
  • Devices:S710
If you have a schema of the XML file you could use the xsd.exe tool to generate a class which has all the properties of the xml. To read the xml file in the class use the XmlSerializer. That way you won't have to parse the xml yourself.

  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users