2 all
First, I want to tell you that I am in programming more then 10 years and that I finished faculty of Math & Computer Science. I am tellilng you this so to know that I excellent understanding of most IT stuff, so to avoid trivial sugesstions, answers, propositions etc...
2 chiph
Yes, I am opeining files.
1. I upload xml file to server's Data Folder.
2. I open this file to find out its root element so to know which schema to load for validation
3. I use above code to load xml and validate it.
When I copy paste this part of code to Win Forms xvr_ValidationEventHandler is called for every error rised by validation process according to schema. I didn't use this procedure originaly but DataSet ability to load and check xml. But this didn't work in ASPX so I thought that there is some reason which I don't understant so I did find alternative code for this on CodeGuru. This code worked yesterday in both WinForms and ASPX.NET. I tested it with various non-valid xml inputs and all errors were detected. I had to restart my computer. After that, I got a message from VS that I don't have access to debug this project (but Conf->Debug->Debug ASPX is TRUE, serverl is localhost, IIS). The message was something like "You don't have privilegies or SQL Server is not alive". I searched MSDN for this error and it displayed bunch of things that can cause this, non of them to be common, like problem with some ports etc.... I didn't have time to anylise this and connection to database was in latter part of the code so I tried to find some workaround to be able to debug (restarting, changing some options back & forth, that kind of stuff, basicly nothing intellegent). I started to hit F11 on random and finally it passed ?!
From that momment it allow me to debug but every now and then it returns to previous behavior and "unfreeze" without me doing anything except hitting F11 over and over.. ?! Anyway, I suspect that this has to do something with XML validation passing without rising errors, don't ask me why. I also guess that somehow ASPX user account has to something with my debug problems but what is the trigger for this behavior I don't know.
The strange thing I noticed is this: first time when SqlConnection.Open rised error that I don't have debug privilegies I noticed that XML validation didn't work correctly. Since I first validate and then open connection to transmit this data do database, I didn't figure out why is XML validation affected with this error, because when it did allow me to connect to database without debuging errors XML suddenly started to work like it should (no code is ever changed here). Then, after system was reset, everything is not working again.... after some time VS allows me to debug but XML validation is still not working.
That is all, explained step by step.
I can captiure my debug session to video if you can obtain more information that way.
2NeilTrain
No errors... non valid XML pass validation and in latter code when I acces its elements and write info in database everything seems normal... except that I have problems with invalid XML fields.
Thank you all very much if you are willing to investigate this with me, I am really confused with this.
Info about my system:
- Dell 2x3GHz Intel CPU, 1GB RAM
- Windows XP SP1 + hotfixes up to date
- IIS 5.1
- VS 2003
- SQL Sever 2000
- Loged as domain user