Hi everybody.
I'm using VS2005 C# to code a smart device project, which should run in Pocket PC 2003 SE emulator. When I try to load a xml document as in this sample
private void Display()
{
try
{
XmlDocument doc = new XmlDocument();
string url = @"D:\NewFolder\Notebook\Notebook\Xml\diary.xml";
doc.Load(url);
DateTime t = dateTimePicker1.Value;
string date = Convert.ToString(t.Day) + "/" + Convert.ToString(t.Month) + "/" + Convert.ToString(t.Year);
XmlNode node = doc.SelectSingleNode("diary[@date = " + date + "]");
textBox1.Text = node.Value;
}
catch (System.IO.FileNotFoundException e)
{
MessageBox.Show(e.Message);
}
A problem occurred like this :
A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll
A first chance exception of type 'System.IO.FileNotFoundException' occurred in mscorlib.dll
A first chance exception of type 'System.IO.DirectoryNotFoundException' occurred in mscorlib.dll
A first chance exception of type 'System.IO.DirectoryNotFoundException' occurred in System.Xml.dll
I presume that the emulator doesn't know the path (url) on PC, but I don't
know how to correct.
Can someone guide me how to correct this problem?
Thank you so much in advance.