Wrox Programmer Forums
|
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics 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 December 16th, 2004, 05:55 PM
Authorized User
 
Join Date: Aug 2004
Posts: 86
Thanks: 0
Thanked 0 Times in 0 Posts
Default Datagrid procedure name

I have created a datagrid with 3 buttons to go to detail page. View, Edit and Delete. Based on the access level of the user, the controls on the detail page are shown. For Edit and Delete, I used Datagrid_EditCommand and Datagrid_DeleteCommand events. What should i use for View. I tried item_command, but then it overrides edit and delete commands and always performs item_command event. I want to disable buttons on the detail page if it is in View mode.

Thanks
renu

 
Old December 22nd, 2004, 01:03 AM
Authorized User
 
Join Date: Aug 2004
Posts: 86
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Never mind. I got it working by using datagrid_itemcommand and then checking for the e.commandname.


 
Old December 22nd, 2004, 01:15 AM
Authorized User
 
Join Date: Aug 2004
Posts: 86
Thanks: 0
Thanked 0 Times in 0 Posts
Default

There is one problem though. How do I use the sort command. Earlier I was using :-
Me.DataSet11.tablename.DefaultView.Sort = e.SortExpression
Me.DataGrid1.DataBind()

But, now I cannot use e.SortExpression as it tells me that "SortExpression is not a member of System.Web.UI.WebControls.DatagridCommandEventArgs ". What is the work around this problem.

Thanks in advance.







Similar Threads
Thread Thread Starter Forum Replies Last Post
Custom paging in Datagrid with datagrid page count madhusrp ASP.NET 1.0 and 1.1 Professional 12 June 2nd, 2008 01:15 PM
Procedure nick1005 MySQL 2 October 18th, 2007 08:41 AM
User COntrol Datagrid inside datagrid rodmcleay ASP.NET 1.0 and 1.1 Professional 3 April 14th, 2007 10:11 AM
Creating DataGrid In Repeater/DataGrid liduwan ASP.NET 1.0 and 1.1 Professional 9 March 6th, 2007 03:31 PM
procedure DARSIN Oracle 6 October 20th, 2004 03:50 AM





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