We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Open .doc from network path?

Thread ID:

Created:

Updated:

Platform:

Replies:

62456 Jun 15,2007 03:59 AM Jun 19,2007 06:56 AM ASP.NET Web Forms (Classic) 3
loading
Tags: DocIO
ttt
Asked On June 15, 2007 03:59 AM

Good morning,

i'm experimenting with DocIO and i found a problem: the moment i try to open a .doc from a network path, my asp.net application just return a message "Storage could not open".
I get the path from a database and i'm trying to use something like:

Dim document As DLS.WordDocument = New DLS.WordDocument

document.Open(CStr(MyPath), FormatType.Doc)

And after that my application return that message.

There's a way to use mapping network path (like p:\blablabla\bla.doc) or absolute path (like \\my-server\bla.doc)?

Sorry for my bad english and thanks for reading. :)

Melba Winshia [Syncfusion]
Replied On June 15, 2007 08:59 AM

Hi Diego,

Thank you for your interest in Essential DocIO.

I tested by opening files from a network path and it seems to work fine. Could you please check the following?

1) Could you please check if you are able to open the file using the System.IO.FileStream

System.IO.FileStream fs = new System.IO.FileStream(CStr(MyPath),System.IO.FileMode.Open);

2) If not could you please check if the ASP.NET process has permissions to read from the network path?

Note:
----
1.Path names are limited to 248 characters
2.The specified path can also refer to a relative path or a Universal Naming Convention (UNC) path for a server and share name.
3.Ensure that your paths are well formed when using methods that accept a path string.
4.If you don’t have permission it will generate FileIOPermission exception.

Kindly let me know if the problem still exists.

Thanks,
Melba

AAA
Replied On June 18, 2007 11:52 AM

Hi Melba!

First of all thanks for your answer, very appreciated.

And finally i solved my problem: it was a permission problem, due to the fact that my was commented and was not intended to! :)

Anyway, it works fine with absolute path (ex. "\\serverx\filename.doc") but it doesn't work with mapped drive and the error is: "Impossibile trovare una parte del percorso Y:\file.doc."
Roughly traslated is: "A part of the path could not be found Y:\file.doc."

If you need the rest of the message tell me so i'll translate it for you.

Thanks for help, keep up the good work!

Melba Winshia [Syncfusion]
Replied On June 19, 2007 06:56 AM

Hi Diego,

Glad to hear that issue is resolved. However I was not able to reproduce any issues with mapped drive. I tested by opening files from mapped drive and it works fine. I think the problem is due to the path not being well formatted. Could you please let us know if you are able to open the file from the mapped drive using System.IO.FileStream?

System.IO.FileStream fs = new System.IO.FileStream("Y:\file.doc",System.IO.FileMode.Open);

This would help us to analyze this issue further.

Thanks,
Melba

CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;