473,803 Members | 2,038 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Get value of checkbox in a datagrid view

How do I get the value of a checkbox in a row in a datagrid view please? I
have tried many methods and nothing workds. This was so much easier in VB
6.0.

THanks for any help you can give me.
Feb 6 '07 #1
1 2593
Try code like:

bool b = (bool)
this.dataGridVi ew1[boolColIndex, someRowIndex].Value;

=============
Clay Burch
Syncfusion, Inc.

Feb 6 '07 #2

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

Similar topics

0
3108
by: andrei | last post by:
Hi Group, I have a checkbox column in a web datagrid which is related to a "Product in stock" property. The grid is in view mode, so the user can't (and shouldn't) change anything in the grid. What I need is to show a "ReadOnly" checkbox in the grid, but not a disabled one (grayed out). I'm using a template column and the only property I can set is "enabled".
1
1222
by: Andre | last post by:
Hi, I need some help with automatically generated checkbox in my datagrid, i'm searching everywhere and can't find a way to do this. In my datagrid i will always have more than one line, with one checkbox on each line (each line is an option for our costumers). But i want to : - have autopostback set to true only on the first (or any other,
2
6566
by: Asha | last post by:
greetings, i'm loading a datagrid and my gird has checkbox, i want these checkboxex to be check based on the value from the db? can someone please show me the code for it? thanks
1
2002
by: irene | last post by:
Hi, I am trying to update the checkbox value in a datagrid. I am using TemplateColumn to add the checkbox to the datagrid and it is showing correct data from the database now. Ideally, the end user will check the checkbox(if it is approved) and then there is a confirmation button on the page. After them make the changes, they will hit the confirmation button so that the database will be updated accordingly. I am not using dataset at this...
2
5458
by: Andre Ranieri | last post by:
Hi folks, I have a datagrid which contains a template item checkbox column. I've included a checkbox as a HeaderTemplate item which fires a server-side function to check or uncheck all the values in the underlying datatable column, and resets the binding to the datagrid. The only problem is that, when the user pages back and forth in the datagrid, their selection is overwritten with the default selection in page load. So, if the...
6
2619
by: Alan Silver | last post by:
Hello, I am data binding a repeater that has a checkbox in the ItemTemplate. The data value coming out of the database is a char(1) field containing either "y" or "n". I want to use this value to set/unset the checkbox. I tried the following in the ItemTemplate... <asp:CheckBox ID="chkShowNpVar" Text="" Checked='<%(DataBinder.Eval(Container.DataItem, "showVar")=="y" ? true :
2
3164
by: Juan | last post by:
Hello Group! I am programmig a windows application. I want to make a multiple selection in a datagrid. My first idea is put a checkbox in a datagrid but i dont a clue. I dont want use checkboxlist because i need multiple data columns. Please, any sample for me? Thanks in advance
4
1237
by: wink martindale | last post by:
Hello All, I am certain this has been asked before, but here goes: How do I add a checkbox to a datagrid that is not related to a field in the database? This checkbox will enable the user to create a custom list by selecting the records they want to view. Any help would be much apprectiated,
0
1105
by: alan | last post by:
Hello, I have got a datagrid with first column as a checkbox. I'm trying to retrieve values from rows with checkbox checked. For one column I'm doing something like: <asp:datagrid id="Grid1" runat="server" DataKeyField="serial" AutoGenerateColumns="True"> <ItemStyle></ItemStyle> <HeaderStyle></HeaderStyle> <Columns>
0
9699
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
10542
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
10068
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
9119
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
7600
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
6840
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
5625
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4274
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
2968
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.