Word cannot fire evetn error from asp.net/C#

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

The following code hangs or gives me a "can not fire event" message

The code works from a windows app.
Fails in ASP.NET on the word.open call

I have done the following:

How to configure Office applications to run under a specific user account
http://support.microsoft.com/defaul...b;en-us;Q288367

Before doing the above the cod use to get an access denied on the
new word.application();


oWordApplic = new Word.Application();
object fileName = "filename.doc";
object readOnly = false;
object isVisible = true;
object missing = System.Reflection.Missing.Value;

// hangs here or returns cant fire event msg
oDoc = oWordApplic.Documents.Open(ref fileName, ref missing,ref readOnly,
ref missing, ref missing, ref missing, ref missing, ref missing, ref missing
,
ref missing, ref missing, ref isVisible,ref missing,ref missing,ref missing,
ref missing);

Any ideas?, I have not found anything to help me yet.
 
While you followed the instruction on Q288367 to configure Office apps to
run under specific user, did you accually configure the user account for
ASP.NET apps, i.e. ASPNET or NETWORK SERVICE(Win2003)? In that article,
IUser_[MachineName] account is mentioned, but this account is not the
account that runs ASP.NET apps by default, unless the ASP.NET app is
configured to use <impersonate="true"> and allows anonimous access.
 
Back
Top