PC Review


Reply
Thread Tools Rate Thread

Delete button inside DynamicTemplate in GridView

 
 
gamesforums@hotmail.com
Guest
Posts: n/a
 
      5th Sep 2008
Hi!

I need to add a delete button to my GridView and wire up the onclick
event to a sub in my vb.code. The grid itself are created in the
codebehing - I have no aspx file that I can use for this.

Here's my code:

Protected WithEvents roleList As New GridView

'create templatefield column for role
Dim roleNameColumn As New TemplateField()
roleNameColumn.HeaderTemplate = New
DynamicTemplate(ListItemType.Header, "Roles")
roleNameColumn.ItemTemplate = New
DynamicTemplate(ListItemType.Item, "Role", False)

'add columns to the gridview
roleList.Columns.Add(roleNameColumn)
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
how to call javascript function on link button inside a gridview. Deep Microsoft C# .NET 2 30th Mar 2010 03:03 PM
DynamicTemplate with Delete btn inside a GridView gamesforums@hotmail.com Microsoft ASP .NET 0 5th Sep 2008 02:55 PM
Button Inside Header template of Gridview--gives error on click divya Microsoft ASP .NET 0 9th Aug 2007 12:04 PM
Add Delete button to GridView pargat.singh@gmail.com Microsoft ASP .NET 3 12th Apr 2007 03:54 PM
Delete Button in GridView FooterTemplate =?Utf-8?B?SmFzb25L?= Microsoft ASP .NET 1 8th Aug 2006 12:23 AM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 07:00 PM.