TechTalkz.com Logo

Go Back   TechTalkz.com Technology & Computer Troubleshooting Forums > Tech Support Archives > Programing Languages > C#(C Sharp)

Notices

Reply
 
Thread Tools Display Modes
Old 15-12-2007, 05:11 AM   #1
DotNetNewbie
Guest
 
Posts: n/a
Re: XPath and XmlNodeList, the horror, the horror!

On Dec 14, 11:43 am, DotNetNewbie <snowman908...@yahoo.com> wrote:
> On Dec 13, 6:12 pm, Jon Skeet [C# MVP] <sk...@pobox.com> wrote:
>
>
>
> > DotNetNewbie <snowman908...@yahoo.com> wrote:

>
> > <snip>

>
> > > Again the error on the webpage is:

>
> > > Exception Details: System.Xml.XPath.XPathException: Expression must
> > > evaluate to a node-set.
> > > Source Error:
> > > foreach (XmlElement page in nodeList)

>
> > Has it definitely load the file correctly? What does it look like in
> > the debugger?

>
> > --
> > Jon Skeet - <sk...@pobox.com>http://www.pobox.com/~skeet Blog:http://www.msmvps.com/jon.skeet
> > World class .NET training in the UK:http://iterativetraining.co.uk

>
> yes the file is loaded correctly, I put debug tag when it loads the
> file, and during the loop.
>
> After it loads the file and hits the forloop, in vs.net I can view
> that the cars.xml file has loaded just fine.


Ok got it to work, I was referencing the child nodes incorrectly!
thanks for all your replies!
  Reply With Quote
Reply

Thread Tools
Display Modes


Google
 


All times are GMT +5.5. The time now is 06:06 AM.


vBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO
Copyright © 2005-2008, TechTalkz.com. All Rights Reserved - Privacy Policy
Valid XHTML 1.0 Transitional