Phllip,
Thanks for the information. I was building the GridView dynamically (kind
of the old fashioned way with a declared SQL data adapter and dataset, etc).
I now am using a checkBoxList which is currently working exactly the way
that I need. For this instance, I think a gridView was a bit of an overkill
possibly.
I actually prefer building the GridViews dynamically as then I feel that I
have more control over them. But I do use SQLDataAdapter when I am building
a simpel gridView.
Thanks again.
"Phillip Williams" wrote:
There are many essential information that you have not provided:
1- Is your GridView built dynamically or declartively?
2- If your GridView is placed declaratively, why not add an
<asp:CheckBoxField >?
3- In which event did you place the code that you posted below?
--
HTH,
Phillip Williams
http://www.societopia.net
http://www.webswapp.com
"Brad" wrote:
I am programatically trying to add a checkBox column to a gridView.
This is what I have to do it (VB):
Dim cbCol As New CheckBoxField
cbCol.Text = "Enter this event"
gvEvents.Columns.Add(cbCol)
When it displays the column, there are no checkboxes.
Maybe I am going about this the wrong way. What I am trying to do is to
present the user with a list of no more than a dozen choices (dates of events
that they can enter). The user should be able to select anywhere from one to
all of the records and I would like to have a check box column to do this.
If a gridView is not a good choice, then should I maybe do a listbox?
Thanks for the information.