473,503 Members | 1,666 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Multiple Checkbox Options

8 New Member
Hi To all,

I'm new here in bytes, I would like to ask for your help on the database the i'm working on. Here are some details
Expand|Select|Wrap|Line Numbers
  1. Name: ________                       Covered Date:__________
  2. #    Process   Mon Tue Wed Thur  Fri    Remarks    Description  
  3. 1       A      Chekboxes      txtbox
  4. 2       B      Chekboxes      txtbox
  5. 3       C      Chekboxes      txtbox
  6. 4       D      Chekboxes      txtbox
  7. 5       E      Chekboxes      txtbox
  8. 6       F      Chekboxes      txtbox
  9. 7       G      Chekboxes      txtbox
That needs to compute/total the number of checkbox ticked for each process for covered period inputted (weekly basis).
I'm having problem in connecting the checkbox to the tables in access and the codes that will compute the checkboxes.

I will appreciate all the help that I can get.....
Thanks!!!
Skiedg
Oct 30 '08 #1
17 3854
NeoPa
32,557 Recognized Expert Moderator MVP
You don't give much detail of your problem and it's not clear what you're having trouble with. Can you clarify the question.
Oct 30 '08 #2
Cuteako
8 New Member
My problem is first how to connect multiple checkbox in a table.
How to sum the checkbox that are ticked for the covered period given.
The description of the form is there are task to be completed weekly mon-fri.
then the user will tick the task that she/he have done.

Fields:

a.Employee ID
b.dates covered.
c.checkbox
d.remarks

Thank you very much for your assistance....
Oct 31 '08 #3
NeoPa
32,557 Recognized Expert Moderator MVP
My problem is first how to connect multiple checkbox in a table.
Each CheckBox is bound to a different (Yes/No) field within the table.
How to sum the checkbox that are ticked for the covered period given.
What defines the period? All fields in a single record? A particular Yes/No (CheckBox) field across all, or even a specified range of, records?

NB. After reading your explanation (which comes after this question) it is clear they should be multiple Yes/No fields in the record. This isn't reflected in your record layout though.
The description of the form is there are task to be completed weekly mon-fri.
then the user will tick the task that she/he have done.

Fields:

a.Employee ID
b.dates covered.
c.checkbox
d.remarks
Ah, some explanation at last, but how can a single CheckBox (c) cover Monday to Friday?
Oct 31 '08 #4
Cuteako
8 New Member
-What defines the period? The user will input the covered period. For example
Start Date: 11/3/2008
End Date:11/7/2008

-Each task will have 5 checkboxes to reflect the monday to friday task.

-I did try to connect the checkboxes to the table using yes/no in the properties ''Control Source" however after connecting the checkbox becomes disable.

Thank you again......
Nov 3 '08 #5
NeoPa
32,557 Recognized Expert Moderator MVP
-What defines the period? The user will input the covered period. For example
Start Date: 11/3/2008
End Date:11/7/2008
I'm thinking more of how it is defined within the form.
-Each task will have 5 checkboxes to reflect the monday to friday task.
This seems contradictory to the statement made in post #3 (quoted in my previous post). This needs to be clarified.
Is it one or the other? It's important (critical) to know this.
-I did try to connect the checkboxes to the table using yes/no in the properties ''Control Source" however after connecting the checkbox becomes disable.
Connecting is done by setting the Control Source property of each CheckBox item to the (or one of the - depending on the actual design) name of the boolean (Yes/No) field in the table.
Nov 3 '08 #6
Cuteako
8 New Member
A.I'm thinking more of how it is defined within the form.
- Textbox for Start Date
- Textbox for End Date
This is is for the covered period.
B. This seems contradictory to the statement made in post #3 (quoted in my previous post). This needs to be clarified.
Is it one or the other? It's important (critical) to know this.
- Sorry but I forgot to indicate that each task has multiple checkboxes
-5 to be exact for each task.
C.Connecting is done by setting the Control Source property of each CheckBox item to the (or one of the - depending on the actual design) name of the boolean (Yes/No) field in the table.
-Yes I did create a table with Yes/No field in the table and did try to connect it but the checkbox become unable.

Thank you for your patience and understanding.
Nov 4 '08 #7
missinglinq
3,532 Recognized Expert Specialist
I've deleted your latest, duplicate thread on this problem. This note will bump this thread back up to the top of the queue. In the future, please don't post duplicate threads. If, after a reasonable time, your problem hasn't been solved, or appears to not be attracting attention, add a note yourself. This will bring it back to the top of the queue, and all of the previous questions/answers will be part of it. Simply reposting your question, as you did, gives no one the benefit of NeoPa's questions or your replies.

Linq ;0)>

Moderator
Nov 9 '08 #8
Cuteako
8 New Member
Hi Everyone,

I really need help on this project; I will give more details so you could understand it more.

The database if for task monitoring (weekly). Employees will log every last day of the week to record what task have they done for the week.

Name: Start Date:
Employee ID: End Date:

Task Mon Tue Wed Thur Fri
1 < > < > < > < > < >
2 < > < > < > < > < >
3 < > < > < > < > < >
4 < > < > < > < > < >
5 < > < > < > < > < >

< > = checkbox
I created 3 tables already;
1st is for list of task
2nd is for task completed where in I used yes/no for Mon-Fri.
3rd is for list of employees with their employee ID’s

I already connect the first row of checkbox in the table of task completed however when I try to check the 2nd row of the task the value of the 1st row defaulted and when I try to change it it doesn’t work how do I go about it

And also I need to sum the checkboxes according to task, employee and by dates also.

I hope someone can help me with my office project.
I will really appreciate any help that you could give.

Thank you so much in advance.
Nov 11 '08 #9
NeoPa
32,557 Recognized Expert Moderator MVP
I'm sorry I've been a little tied up during the last week and haven't had time to look at this problem. I hope to find time shortly to give this some more attention. Thank you for your patience.
Nov 11 '08 #10
Cuteako
8 New Member
Thank you for your time.
Hope to hear you soon..
Nov 12 '08 #11
PianoMan64
374 Recognized Expert Contributor
Thank you for your time.
Hope to hear you soon..
Dear Cuteako:

It is very clear to me what it is that you're trying to do, the problem is that what you're concept and the model that your trying to do with are totally incompatible with each other.

For example, The reason for the table only have one day, with a completed checkbox is so that you can see when the particular item was completed?

Since you're using the form to display multi-records on a form that supports only 1 record at a time, this is where the rub is.

To teach you what you need to know, would take a great deal of time to teach, sine you're new to VBA.

Think of it this way, you can either redesign your form to allow a list of projects in, say a list box that they can click on and highlight, and then click some button to indicate that they are complete.

this would then replace what you currently have on your form with something that would allow them to look at pending projects, and then you can tie a click event to a button that would see which items are selected on the ListBox Control and then update each of those records with a DateTime Stamp or a date, or whatever you wanting in the date field.

To be able to do what you're talking about you would have to create an event for each and every check_box, then have it locate that record that is assign to that checkbox and locate the Project, and then update it based on which check_box was clicked on.

Talk about a great deal of code.

Not my idea of a good time. If you would like any code examples of what I'm talking about, please feel free to let me know, or some here in the forum would be more than happy to answer any questions.

Just keep in mind that you have to explain exactly what you're trying to do and how you want it to work. You don't need to know all the nitty-bitty details, but just the overall concepts and then that gives you what you need in order to create what it is that you want.

Hope that helps,

Joe P.
Nov 12 '08 #12
NeoPa
32,557 Recognized Expert Moderator MVP
Hi Everyone,

I really need help on this project; I will give more details so you could understand it more.

The database if for task monitoring (weekly). Employees will log every last day of the week to record what task have they done for the week.

Name: Start Date:
Employee ID: End Date:

Task Mon Tue Wed Thur Fri
1 < > < > < > < > < >
2 < > < > < > < > < >
3 < > < > < > < > < >
4 < > < > < > < > < >
5 < > < > < > < > < >

< > = checkbox
I created 3 tables already;
1st is for list of task
2nd is for task completed where in I used yes/no for Mon-Fri.
3rd is for list of employees with their employee ID’s

I already connect the first row of checkbox in the table of task completed however when I try to check the 2nd row of the task the value of the 1st row defaulted and when I try to change it it doesn’t work how do I go about it

And also I need to sum the checkboxes according to task, employee and by dates also.

I hope someone can help me with my office project.
I will really appreciate any help that you could give.

Thank you so much in advance.
From this post it does become clear that you have some problems with your design. Read what Joe has to say on the matter as it's helpful. Also check out (I'd bookmark it) Normalisation and Table structures.

As far as the simple question of adding across the number of True checkboxes is concerned, you can use code similar to the following (using your own control names of course) :
Expand|Select|Wrap|Line Numbers
  1. With Me
  2.   intSomeVal = IIf(.chkMon, 1, 0) + _
  3.                IIf(.chkTue, 1, 0) + _
  4.                IIf(.chkWed, 1, 0) + _
  5.                IIf(.chkThu, 1, 0) + _
  6.                IIf(.chkFri, 1, 0)
  7. End With
On a continuous form (as you seem to have) this will only apply to the currently selected record.

NB. While I provide this answer, it's more important that you realise that the structure of your database must "fit". Otherwise you will be forever fighting the design, instead of having it work naturally for you.
Nov 12 '08 #13
FishVal
2,653 Recognized Expert Specialist
Hello, gentlemen.

@Cuteako.

Dear Cuteako,
I quite agree with NeoPa as for pointing you to Database Normalization article.
Normalization is a crucial point in database design and should never be traded off to suit table structure for interface implementaion simplicity.
I agree with PianoMan too - Access doesn't have a "native" mechanism to edit such kind of data stored in normal tables in a way you want. That doesn't mean it is impossible at all, it will require coding to add desired functionality to what Access has built in.

Here I will attach a simple example with the following features:
  • Form based on crosstab query. Crosstab query is not updateable - so, VBA code behind MouseDown events of form controls modifies source table directly.
  • Employee is predefined as the first in the correspondent table and week is predefined as that starting from #11/9/2008#. When you get aquainted with the design you will be able to workup these two features.

Regards,
Fish
Attached Files
File Type: zip WeekTasks.zip (19.5 KB, 111 views)
Nov 12 '08 #14
Cuteako
8 New Member
Hi Everyone,

I will study my forms, i think i really need to recontruct it.

Thank you so much for your inputs.
I really appreciate it.

Hi PianoMan64 ,

Can you give me some sample code of your suggestions.

Thank you so much everyone for you help, I hope this will not be the last.....

= )
Nov 13 '08 #15
NeoPa
32,557 Recognized Expert Moderator MVP
I hope you manage to get this sorted out.

Let us know if you have further problems :)

Welcome to Bytes!
Nov 13 '08 #16
Cuteako
8 New Member
Hi PianoMan64 ,

Can you give me some sample code of your suggestions.

Thanks again......
Nov 15 '08 #17
PianoMan64
374 Recognized Expert Contributor
Hi PianoMan64 ,

Can you give me some sample code of your suggestions.

Thanks again......
I've attached an example of what I'm talking about.

Hope that helps,

Joe P.
Attached Files
File Type: zip ListControlExample.zip (16.6 KB, 120 views)
Nov 16 '08 #18

Sign in to post your reply or Sign up for a free account.

Similar topics

3
13205
by: jason | last post by:
How does one loop through the contents of a form complicated by dynamic construction of checkboxes which are assigned a 'model' and 'listingID' to the NAME field on the fly in this syntax:...
4
3798
by: Dave Parrin-Bull | last post by:
Hi all, I have been asked (nay told!) to do a quiz for a webpage at work, now I can do the basic things like getting the radio boxes up there and assign values to them but here is what they...
1
1957
by: Paul Goodley | last post by:
Typically, shopping carts add a single item at a time, so it's easy to prompt the user for information needed for the order, but what if the shopping cart needs to process thirty items at once? I...
0
1977
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...
1
5313
by: Yelena Varshal via AccessMonster.com | last post by:
Hello, What are the pre-requisites / conditions for the ability to create multiple connections to MS ACCESS database and what is the precedence of its application? adModeShareDenyNone in the code,...
3
5126
by: mountain.dog | last post by:
I have a query that shows a list of options that a user can toggle on or off using a checkbox. query... form... while($row = mysql_fetch_array($result))... <input name="menu_show_attribute"...
4
5456
by: ATDave | last post by:
So basically I'm just creating a form that I want the results e-mailed to somebody. I have everything working except for the checkmark sections that can have multiple answers. I'm a newbie when...
25
5364
by: bonneylake | last post by:
Hey Everyone, Well i am not sure if my question needs to be here or in coldfusion. If i have my question is in the wrong section i am sorry in advance an will move it to the correct section. ...
482
27256
by: bonneylake | last post by:
Hey Everyone, Well i am not sure if this is more of a coldfusion problem or a javscript problem. So if i asked my question in the wrong section let me know an all move it to the correct place. ...
3
4912
by: didi86 | last post by:
Please help me to adding multiple row at a time... // Last updated 2006-02-21 <script language="javascript"> function addRowToTable() { var tbl = document.getElementById('tblSample'); ...
0
7203
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,...
0
7087
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
6993
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5579
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,...
1
5014
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...
0
4675
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...
0
3168
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1514
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 ...
1
737
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.