Wrox Programmer Forums
Go Back   Wrox Programmer Forums > ASP.NET and ASP > Other ASP.NET > ASP.NET Espanol
|
ASP.NET Espanol Esta es una lista de correo dedicada al intercambio de conocimiento sobre ASP.NET en el idioma español.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET Espanol section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old October 7th, 2008, 01:11 AM
Registered User
 
Join Date: Oct 2008
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default HyperLink in a gridview contro to open word docmen

I need to display an hyperlink in a gridview which is the path to the document. I would like to open microsoft word when a user clic on the hyperlink. I set the fallowing code in asp.net 2.0

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Página sin título</title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <asp:GridView ID="GridView1" runat="server" AutoGenerateColumns="False" DataKeyNames="Nombre"
            DataSourceID="SqlDataSource1" Style="position: static">
            <Columns>
               <asp:TemplateField HeaderText="myTemp">

             <ItemTemplate>

                <asp:HyperLink ID="HyperLink1" runat="server" Text='<%# Eval("Curriculum") %>' NavigateUrl='<%# Eval("Curriculum") %>'></asp:HyperLink>
        </ItemTemplate>

              </asp:TemplateField>

            </Columns>
        </asp:GridView>
        <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionStringDatos %>"
            SelectCommand="SELECT [Nombre], [Curriculum] FROM [Datos]"></asp:SqlDataSource>

    </div>
    </form>
</body>
</html>


What more do I have to do???

Thank a lot....






Similar Threads
Thread Thread Starter Forum Replies Last Post
Opening a text file using hyperlink in a gridview absu General .NET 1 March 6th, 2009 02:03 AM
Hyperlink Targeturl to open within the curr frame ismailc XSLT 12 September 11th, 2008 04:52 AM
Open Crystal Report from hyperlink aspBegineer83 Crystal Reports 0 November 24th, 2007 02:15 PM
GridView Hyperlink ki_ki ASP.NET 2.0 Professional 25 March 8th, 2007 03:30 PM
Using Hyperlink field in GridView asp_convert ASP.NET 2.0 Basics 2 February 7th, 2007 07:33 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.