Last post Apr 12, 2010 11:51 AM by hiteshspatel
Apr 12, 2010 10:29 AM|nickreece|LINK
I'm very new to this and struggling quite a bit I been tasked to create a site that uses can request environment access; however I'm falling at the first hurdle.
This is probably a very simple task............
I'm using Visual Web Developer 2008 Express Edition
I need to call a Word document from a Buttont1_Click but I can't find the code i need to use, or work out the help files within Visual Web Developer 2008 Express Edition to work this out.
Partial Class _Default
Protected Sub Button1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button1.Click
WHAT CODE NEEDS TO GO HERE!!!!!!!!!
Apr 12, 2010 10:50 AM|hiteshspatel|LINK
Do u want to open the word document serverside or client side? (means where does this doc file resides?)
if it is at server then Process.start('winword','path of file')
and if it is at client then, it would be pain in neck, you would have to do something in client side scripting...
this link might help you,
Apr 12, 2010 11:29 AM|nickreece|LINK
Firstly thanks for your quick response!
The document will be located on the server...
So I just need to add this code to the button1_click 'Process.start('winword','path of file')' changing the 'path of file' to where the file is located?
Apr 12, 2010 11:51 AM|hiteshspatel|LINK
Yup you are right...
see the article in MSDN for more information,
do not forget to add system.diagnostics namespace also.
-Mark as an answer if this has really helped you.