nV News Forums

 
 

nV News Forums (http://www.nvnews.net/vbulletin/index.php)
-   Software Development (http://www.nvnews.net/vbulletin/forumdisplay.php?f=53)
-   -   Loading XML error (.net 1.1) (http://www.nvnews.net/vbulletin/showthread.php?t=88120)

Sycario 03-14-07 12:35 PM

Loading XML error (.net 1.1)
 
I am trying to load an xml document but it blows up every time. I've done this before without a problem.

Dim xmlDoc As New Xml.XmlDocument
If IO.File.Exists(XMLFile) = False Then
ThrowError("Unable to locate the setup xml.", True)
ElseIf IO.File.Exists(XMLFile) Then
xmlDoc.Load(XMLFile)

Then it errors on the load with:
Additional information: System error.

In the debug it says:
XMLFile "E:\Dev\UllsaSetup\UllsaSetup\bin\setup.xml" String

Any ideas?

Head_slinger 03-22-07 07:37 PM

Re: Loading XML error (.net 1.1)
 
can you post more of the code please.

supra 03-22-07 08:04 PM

Re: Loading XML error (.net 1.1)
 
Quote:

Originally Posted by CaNiBuS

In the debug it says:
XMLFile "E:\Dev\UllsaSetup\UllsaSetup\bin\setup.xml" String

is this the actual path or is it

"E:\Dev\UllsaSetup\bin\setup.xml"
not
"E:\Dev\UllsaSetup\UllsaSetup\bin\setup.xml"

Sycario 03-29-07 12:13 PM

Re: Loading XML error (.net 1.1)
 
That was the correct path. It's usually something simple with an error that makes no sense. In this case the xml had <Replace> and </replace>. Just one capital letter made it give a system error. You'd think that the errors might be a little more helpful sometimes.....

supra 03-29-07 08:44 PM

Re: Loading XML error (.net 1.1)
 
hehe yeah but u should already know xml is case sensitive.

i would use a try/catch if u want more details on the error instead of throwerror

Dim xmlDoc As New Xml.XmlDocument
Try
xmlDoc.Load(XMLFile)
Catch ex as Exception
msgbox(ex.tostring)
End Try

Sycario 03-31-07 12:12 PM

Re: Loading XML error (.net 1.1)
 
Yeah, I know it's case sensitive. I didn't make the layout of the XML. Noticing 1 capital letter out of place isn't easy for me, I can't even find a loaf of bread on the counter when it's right in front of me. The only reason I found it was because I opened it with IE7 and it told me the tags didn't match.


All times are GMT -5. The time now is 05:52 AM.

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.