Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Store DataSet on Sharepoint: ReadXml fails while WriteXml works flawlessly

I have a simple win forms application which loads/saves datasets into XML files. As long as I'm working with file shares or the local file system all is good.

Using the standard open file/save file dialog on my Windows 8 box, allows me to browse to my sharepoint using

https:// some sharepoint host

and I can browse the sharepoint sites/projects and document libraries.

Here's the weird part (because I didn't expect it to work like this at all): When I use the file save dialog to browse to a sharepoint document library, the path is converted into something like '\sharepointhost@SSL\somepath\somemorepath\somefile.xml'

Passing the above path to the DataSet WriteXml method works fine and the file is correctly written to the document library.

Passing the very same path to the DataSet ReadXml method doesn't work and I get an exception: "Invalid URI: The hostname could not be parsed."

What am I missing here. I mean, I expected both methods to use the same code to parse/resolve the path.

like image 887
Stefan Koell Avatar asked Nov 30 '25 12:11

Stefan Koell


1 Answers

Are you able to check if your code works on non-secured (http) connection? Maybe this error applies to your scenario?

XmlReader for webdav path with ssl (ReadXml internally uses XmlReader).

like image 51
Marek Kembrowski Avatar answered Dec 03 '25 01:12

Marek Kembrowski