Opening a document read only


#1

I have a requirement to open an existing MS Word document (not created by ASPOSE) and to extract data from the document and fill in text boxes dropdowns etc on and ASP.NET page.

I don't have problem doing this EXCEPT when someone may already have the document open in Word somewhere else.

Is it possible to open the document as a readonly document when peforming something like dim awDoc = new document(filename)?

Thanks,

Anthony


#2

The following technique can be used to open document in Aspose.Words which is already held opened by MS Word:

// Copy document to a temporary file.

File.Copy(filename, filename + ".tmp", true);

// Open document in Aspose.Words.

Document doc = new Document(filename + ".tmp");

// Remove the temporary file.

File.Delete(filename + ".tmp");

Best regards,


#3

Thanks

AnthonyEmbarrassed [:$]