Error when setting Credentials property of an ASMX

A

AC [MVP MCMS]

I have a console app that is working with a Web Service on another remote
box. Suddenly when I try to assign the DefaultCredentials from the
CredentialCache to the Credentials property of the Web Service, I'm getting
the following error:

- An unhandled exception of type 'System.Xml.XmlException' occurred in
system.xml.dll
- Additional information: System error.

Now, the wierd stuff.
1) My app is still being developed... but when I've tested debug builds, it
works about 90% of the time (it = assigning the Credentials property)...
sometimes this error would pop up, kill the process, but all I'd have to do
is just rerun it and it would work fine. Chalked it up to one of those "I'll
figure this out later" and listed it as a bug.
2) The statement is wrapped in a try-catch, but it's breaking on the line
that's assigning the value. I've tried to put a breakpoint and step into it,
but no luck, once it hits that line, it blows up. I've even tried to trap
the exception within the CATCH, but it won't get that far.
3) I've made some changes to the code that handles the response back from
the Web Service, but that code isn't called until after the Credentials are
set. Since I made these changes, the error happens every time now.

I've rolled back my changes, even commented out everything after I set the
Credentials, but the error still keeps popping up. Hard to isolate it or
even track down what the inner exception is because I can't trap the
Exception.

Ideas?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,996
Messages
2,570,238
Members
46,826
Latest member
robinsontor

Latest Threads

Top