-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: DesignedforDOTNet
Message 1 in Discussion

hi..... Am trying to open a word app in asp.net. the code i use is as given below, on 
page_load() ***********************************************************  
object fileName = "c:\\test.doc"; 
object readOnly = false; 
object isVisible = true; 
object missing = System.Reflection.Missing.Value; 
Word.ApplicationClass oWordApp = new Word.ApplicationClass(); 
Word.Document oWordDoc = oWordApp.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); 
oWordDoc.Activate(); 
oWordApp.Selection.TypeText("This is the text"); 
oWordApp.Selection.TypeParagraph(); 
oWordDoc.Save(); 
oWordApp.Application.Quit(ref missing, ref missing, ref missing); 
******************************************************************* 
when i run the application, the page prompts me with a user name and password dialog, 
i have tried all combinations of my username and password, but nogo. 
I have made the asp_net account as the admin account. 
I have also impersonated the current user by adding  
<identity impersonate="true"/>  
in web.config in the authentication section. 
Am i missing something, how to prevent this and get this small piece of code to 
work??? 
cheers 
kannan

-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/BDotNet/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to