mark <dm********@tin.it> typed:
I have this problem and I hope someone can solve it.
thanks in advance.
when I click on a button over a datagrid, i need to open a new windows
with in it a word document that is located on a directory joined to
the server.
how can I do?
Marco Dell'Oca
Milano Italy
You can do that following this steps:
- Create a client script to open a new window using a script language like
Javascript
(
http://msdn.microsoft.com/library/de...uthor/dhtml/re
ference/methods/open_0.asp)
- Insert it using the Page.RegisterClientScriptBlock at run-time
(
http://msdn.microsoft.com/library/de...-us/cpref/html
/frlrfSystemWebUIPageClassRegisterClientScriptBlock Topic.asp)
- Refer this script from the onclick attribute of the datagrid button. This
can be done during the ItemDataBound Event
(
http://msdn.microsoft.com/library/de...-us/cpref/html
/frlrfsystemwebuiwebcontrolsdatagriditemeventhandle rclasstopic.asp)
- Set a Session variable to store the file name of the file to open
- Create a page with some algorithms to open the file or display a message
if cannot open it.
......try your solution
P.S.
I'm seeing you are italian. If you like you could use this newsgroup
public.microsoft.it.dotnet.asp to post your question in italian ;-)
--
Davide Vernole
MVP ASP/ASP.NET
Microsoft Certified Solution Developer