Last post Jul 02, 2008 10:38 PM by rcreddych
Mar 29, 2007 01:32 PM|QasimRaza|LINK
I have created a WebService that is created with the aim in mind to automate Microsoft Office 2003 word document. WebService works fine most of the time and do the required job means placing data in the word document that is placed some where on FileServer.
But i do not know what happens behind the scene that some times WebService throws the following Exception and then stops working further.
System.Runtime.InteropServices.COMException (0x800706BE): The remote procedure call failed.
and I have observed that it happens when Webservice is trying to save the document.
One more problem that appears after this is that WinWord.exe remains open when I check in the Task Manager.
Here below is just a abstract of the logic that my webService is using.
I have made the area about which I have doubt bold.
Public Function ModifyDocumentFields(ByVal strParamFilePath
ByVal strValueNeedtoPlaceInDocument as String
objWordApplication = New word.Application
objWordDocument = New word.Document
objWordDocRange = objWordDocument.Range(missing, missing)
objWordApplication.DisplayAlerts = word.WdAlertLevel.wdAlertsNone
IntResult = 0
objWordDocument.Close(word.WdSaveOptions.wdDoNotSaveChanges, missing, missing)
objWordApplication.Quit(missing, missing, missing)
If Not IsNothing(objWordDocTable)
Jul 02, 2008 10:38 PM|rcreddych|LINK
I have the same kind of problem, any help is apreciated.