Wrox Programmer Forums
|
.NET Web Services Discussions about .NET XML Web Service technologies including ASMX files, WSDL and SOAP.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the .NET Web Services 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 May 17th, 2004, 03:49 AM
Friend of Wrox
 
Join Date: Sep 2003
Posts: 101
Thanks: 0
Thanked 0 Times in 0 Posts
Default Buttons in datagrid

Hi

I am doing application in asp.net using vb
In addtion to Del and Edit buttons I want to display Accept and Reject buttons in my datagrid.
Here again based on some codition want to hide reject button .
When user click on Accept button want to perform some operation.How to do it .

Pl help me.

My code is like below but its not allowing onclick event giving error.

<asp:TemplateColumn>
    <Template>
        <asp:Button id="Button1" runat="server" Font-Size="8" Font-Name="Times New Roman" Text="Accept"
        height="18" Width="17" OnClick="AccAmt()" />
    </ItemTemplate>
</asp:TemplateColumn>


<asp:TemplateColumn>
    <Template>
        <asp:Button id="Button1" runat="server" Font-Size="8" Font-Name="Times New Roman" Text="Reject"
        height="18" Width="17" OnClick="RejectAmt()" />
    </ItemTemplate>
</asp:TemplateColumn>

 
Old May 23rd, 2004, 06:31 AM
planoie's Avatar
Friend of Wrox
 
Join Date: Aug 2003
Posts: 5,407
Thanks: 0
Thanked 16 Times in 16 Posts
Default

I think using the OnClick attribute like you have there is what you want. Except get rid of the () on each of those and try it.





Similar Threads
Thread Thread Starter Forum Replies Last Post
datagrid command buttons CyberW ASP.NET 3.5 Basics 21 November 29th, 2008 04:02 PM
Buttons in DataGrid Template Column divsalar ASP.NET 1.x and 2.0 Application Design 1 February 1st, 2005 03:37 PM
A pair of Radio Buttons in a datagrid cell acorbo ASP.NET 1.0 and 1.1 Professional 1 October 29th, 2004 02:33 PM
Datagrid command buttons badgolfer ASP.NET 1.0 and 1.1 Basics 22 July 27th, 2004 02:42 AM





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