473,322 Members | 1,421 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Getting Checkboxes

I have a page where I dynamically create checkboxes. When the time comes I
need to know if any of them checked and if they are check I need to update
DB to reflect the changes on the page.
I know the ID's of checkboxes than are on the page but I can not capture
them in any way. I tried looping thought the Controls collection with
different way to capture the checkbox control but no success. Please
help!!!!!!!!
Nov 20 '05 #1
1 866
Cor
Hi Ruslan,

I asume it is a webpage, the trick is that "me.findcontrol("form1")"
and then for each ctl in "frm.controls", that is nowhere in the
documentation.

It is with textboxes

\\\
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
Dim frm As Control = Me.FindControl("Form1")
Dim ctl As Control
For Each ctl In frm.Controls
Dim tb As TextBox
If TypeOf ctl Is TextBox Then
tb = DirectCast(ctl, TextBox)
tb.Text = String.Empty
End If
Next
///
I hope this helps a little bit?
I have a page where I dynamically create checkboxes. When the time comes I
need to know if any of them checked and if they are check I need to update
DB to reflect the changes on the page.
I know the ID's of checkboxes than are on the page but I can not capture
them in any way. I tried looping thought the Controls collection with
different way to capture the checkbox control but no success. Please
help!!!!!!!!

Nov 20 '05 #2

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

Similar topics

7
by: charliewest | last post by:
Hello - I'm using a Repeater control to render information in a very customized grid-like table. The Repeater control is binded to a DataSet with several records of information. Within the...
4
by: tshad | last post by:
I can't seem to get my checkboxes to get checked for some reason. I have 2 Datagrids and they are named Datagrid1 and Datagrid2. My code is: ...
1
by: vinod | last post by:
Hi, I have a form wherein there are around 200-300 rows of homogenous data, each having around 30 input fileds of its own.So totally, there are more than 6000 input fields . Now, when the user...
6
by: rishabhshrivastava | last post by:
Hey All, Can someone suggest me a way to get the values of CheckBox(es) selected in a CheckBoxList control using JAVASCRIPT. I am pasting my current code gere but its not working need some...
3
by: somaskarthic | last post by:
Hi How to get the values of dynamically created checkboxes which are checked and unchecked (for both the conditions). Only the selected checkbox values are posted as 'On' . How can i get the value...
1
by: pluggy | last post by:
Hello, I am trying to display, on an MS Access form (frm024), the contents of a table (tbl_TypeOfOrgs). The table has two fields, OrgTypeID and OrgType. It currently has 4 records. This table...
4
by: jeet | last post by:
Plz help me.Problem is that On the first page I display all other user with checkbox and give user option to select only two user which he wants to send message. Tell me please how I'll get those...
7
by: jodleren | last post by:
Hi all! I have a problem - I have a list of checkboxes, with certain data... the point is, that some of them are set, and the important thing for mere is to get those values, which have changed...
1
Markus
by: Markus | last post by:
I have a datagridview on one of my forms, and in the grid there are checkboxes on each row. The checkboxes are so the rows can be deleted. However, I am unable to find (I have googled) the way of...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

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.