473,785 Members | 2,395 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Enabled checkboxes in gridview control

Hi,

I am trying to create a ASPX page which will list items with a checkbox
beside each. The user has to be able to select items using the checkbox
to do some further processing. If I use a gridview control, the
checkboxes are all disabled, and I find that I have to have a Edit
button for each row, and after clicking the Edit button, the row check
box gets enabled.

Is there any way that I can use the Gridcontrol (or any other ASPX web
control) to display items with enabled checkboxes without having the
user to click on Edit button before he can check/uncheck the checkbox?

Or should I have to use inline scripts to generate the items and
checkboxes? Any sample codes available.

I really appreciate any help in this.

Thanks,
Deepa

Dec 23 '06 #1
2 11236
Sure you can -- check out this code sample at ASPNet101.com:
http://aspnet101.com/aspnet101/aspne...=GridViewCheck

Once the checkboxes are checked - then, you can create a function/sub to go
through each row, and for each one that has a checkbox actually checked, you
can do anything you want to or for that row.
--
David Wier
MVP/ASPInsider
http://aspnet101.com
http://aspexpress.com

<de************ *@gmail.comwrot e in message
news:11******** **************@ 79g2000cws.goog legroups.com...
Hi,

I am trying to create a ASPX page which will list items with a checkbox
beside each. The user has to be able to select items using the checkbox
to do some further processing. If I use a gridview control, the
checkboxes are all disabled, and I find that I have to have a Edit
button for each row, and after clicking the Edit button, the row check
box gets enabled.

Is there any way that I can use the Gridcontrol (or any other ASPX web
control) to display items with enabled checkboxes without having the
user to click on Edit button before he can check/uncheck the checkbox?

Or should I have to use inline scripts to generate the items and
checkboxes? Any sample codes available.

I really appreciate any help in this.

Thanks,
Deepa

Dec 23 '06 #2
Thanks a lot for your quick reply!!
David Wier wrote:
Sure you can -- check out this code sample at ASPNet101.com:
http://aspnet101.com/aspnet101/aspne...=GridViewCheck

Once the checkboxes are checked - then, you can create a function/sub to go
through each row, and for each one that has a checkbox actually checked, you
can do anything you want to or for that row.
--
David Wier
MVP/ASPInsider
http://aspnet101.com
http://aspexpress.com

<de************ *@gmail.comwrot e in message
news:11******** **************@ 79g2000cws.goog legroups.com...
Hi,

I am trying to create a ASPX page which will list items with a checkbox
beside each. The user has to be able to select items using the checkbox
to do some further processing. If I use a gridview control, the
checkboxes are all disabled, and I find that I have to have a Edit
button for each row, and after clicking the Edit button, the row check
box gets enabled.

Is there any way that I can use the Gridcontrol (or any other ASPX web
control) to display items with enabled checkboxes without having the
user to click on Edit button before he can check/uncheck the checkbox?

Or should I have to use inline scripts to generate the items and
checkboxes? Any sample codes available.

I really appreciate any help in this.

Thanks,
Deepa
Dec 25 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1994
by: Faybert | last post by:
Hello, and Thanks in advance for any light you might shed on my troubles. I'm trying to setup a series of checkboxes, or a checkboxlist to control the results that are shown on a gridview control. I have a column in my database that hold the current status of the items in there. If I used a checkboxlist and populate it with my options, and set the SQL statement on my gridview control to: "SELECT , , , FROM WHERE
2
3600
by: Chris Davoli | last post by:
How do you enable a check box in the GridView. I selected Checkbox Field in the Columns of the GridView, and the check box shows up in the Grid view, but it is disabled. How do I enable it so I can check/uncheck it. Also, what event do I use to check it for a value? Any articles out there? -- Chris Davoli
0
2745
by: joebob8000 | last post by:
This seems like a simple task, but my 6 year old roots in classic ASP must be causing me trouble with my current problem. I am looking to provide a search for users in which they can select multiple categores (check boxes) and view only the results in those categories in a gridView control. My goal is to do so for movies, so an example would be if the user checks comedy and childrens then they would only get childrens comedies and the...
2
13201
by: antonyliu2002 | last post by:
I've been googling for some time, and could not find the solution to this problem. I am testing the paging feature of gridview. I have a very simple web form on which the user can select a few fields to be included in the table, which is to be bound to the gridview. The web form looks like so (Don't worry about the stupidity of this web form for now.):
0
4197
by: =?Utf-8?B?V0I=?= | last post by:
Hi, I have a .NET page which has a gridview of customers from Northwind database. There's a checkbox for each customer and the gridview allows paging. I would like to be able to persist the checkbox status while paging. I'm starting with the code below but I can't get it to work. You can check some of the checkboxes and when you click on the pager, no selection is reflected by the trace. Why's that?
2
2830
by: GISmatters | last post by:
I have unbound checkboxes in a nested gridview to allow multi-selection of "child" rows. For context, the parent gridview rows are for large "reports", the child rows are for various specific files comprising each report. I want the user to be able to select an arbitrary collection of report files and have them emailed by clicking an "Email selected files" button. Everything displays properly, including the checkboxes for each child row (each...
1
4520
Frinavale
by: Frinavale | last post by:
I'm working on an ASP.NET application using VB.NET for server side code. I have a GridView listing a bunch of stuff. Above the GridView I have a checkbox named "ChkBx_SelectAll". If this checkbox is checked, all of the rows in the GridView are checked, if this checkbox is unchecked, all of the rows in the GridView are unchecked. This checking/unchecking of the checkboxes in the GridView is handled by a JavaScript method: function...
1
1270
by: =?Utf-8?B?Um9iYnlE?= | last post by:
I'm having trouble picking up the checked state of checkboxes in my GridView. I'm working in VS2008. I added a TemplateField via smartTag "Edit Columns". My GridView markup is: <asp:GridView ID="GridViewProspectSearch" runat="server" CellPadding="4" EmptyDataText="No prospects found." ForeColor="#333333" GridLines="None"> <FooterStyle BackColor="#990000" Font-Bold="True" ForeColor="White" />
5
3821
by: =?Utf-8?B?U2F2dm91bGlkaXMgSW9yZGFuaXM=?= | last post by:
Can I set the Enabled or Visible properties of the controls (textboxes, checkboxes) displayed by default in edit mode, depending on the value of some other column? Or must I convert the column to a template column first? What I mean is, I can correctly get the value of the default textbox in a gridview cell when edited, using: s = CType(grd_users.Rows(index).Cells(4).Controls(0), TextBox).Text but I can't set that textbox to disabled...
0
9647
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10356
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10161
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
9958
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8986
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7506
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6743
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5523
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2890
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.