Solved

How do you you replace a Gridview HyperLink with a Button

Posted on 2009-04-02
2
248 Views
Last Modified: 2012-05-06
I want to replace the HyperLink in GridView template with a Button labelled submit which will perform same actions show below. Please show be the replacement code how to do this.

                              <itemtemplate>
                                <asp:HyperLink ID="myForm" runat="server" Text='submit'>
                                    NavigateUrl='<%# "FormDetails.aspx?cust_id=" + Eval("cust_id")%>' />
                            </itemtemplate>
0
Comment
Question by:tcmmaxt
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 27

Accepted Solution

by:
nmarun earned 125 total points
ID: 24049850
0
 
LVL 4

Assisted Solution

by:siancell
siancell earned 125 total points
ID: 24050386
You can try and use a regular button,
<input type="button" value="submit" onclick="window.location='FormDetails.aspx?cust_id=<%# Eval("cust_id")%>'" />

Place that inside the item template tags.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
IEnumerable<T> to a List<T> 8 66
VB.NET Textbox input validation 4 77
disable data migrations in visual studio 2017 4 67
How to set focus on a dynamic control 18 49
IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
Problem Hi all,    While many today have fast Internet connection, there are many still who do not, or are connecting through devices with a slower connect, so light web pages and fast load times are still popular.    If your ASP.NET page …
I've attached the XLSM Excel spreadsheet I used in the video and also text files containing the macros used below. https://filedb.experts-exchange.com/incoming/2017/03_w12/1151775/Permutations.txt https://filedb.experts-exchange.com/incoming/201…

734 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question