473,378 Members | 1,427 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,378 software developers and data experts.

Setting a Value in a Table based off of Selection in a Comb BOx

6
I have access 2003 on Windows XP.

So what i am trying to do is edit a record in a table based off of a specific combo box selection. I know how to make the combo box change the values in a table that it is bound to. Whe i am trying to do is have one of the selections in teh combo box enter a value in a field that it is not bound to.

Specifically, i have employee status (new hire, manager, term, LOA) in a combo box that is linked to an employee info table. In that table i have a "count" field which when LOA (leave of Absence) is seleced in the status box. the count number should be set to "0" since the will not be contributing work. I think it might have something to do with a "select case" code but that is just a guess.

thank s
j
Jul 10 '07 #1
3 1617
nico5038
3,080 Expert 2GB
Looks to me you have a design issue at hand.
Best not to record a count value in your table. Best to have an additional tblStatus table with the Status values and a field "WorkingDay" that holds a 1 or 0.

In a query you can JOIN your table with this table and sum the "WorkingDay" field to get the number of working days.

Getting the idea ?

Nic;o)
Jul 10 '07 #2
jayo17
6
i think i get what you are talking about. But my count isnt going to be a daily count of whether people are working. it is meant to be a reference for a day/month/quarter of how many bodies we have to work. Some people are only considered 1/2 because they might have other duties, while someone might be working full time so we can count them as a full person, or a 1.

does this still warrant another table you think?

i also have another question. i have a text box that is filled by a selection of an item in a combo box, but the text field has a # ID showing up. it is the correct ID but i want it to show the word equivelent.
Jul 10 '07 #3
nico5038
3,080 Expert 2GB
Hmm, so the field shouldn't be "connected" with the status :-)
Best to have a separate field to hold the "percentage available", thus 100%, 50%, but also other values can be used.

I get the impression that the connection of the absence status is not really related to the job table. I envision that a person is available for 50% for a certain job. The Absence is recorded in general per date and thus "separate". I would however need more info to judge about that.

For a combobox with two fields you need to make sure it's source holds the two fields (IDand description). Under the Format tab of the properties window make sure that there are 2 columns and that the width is set to 0 (zero).
Thus the first column will be suppressed and only the description will show.

Nic;o)
Jul 10 '07 #4

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

Similar topics

4
by: dmiller23462 | last post by:
So here's my problem.....I need to set up different email distributions based on which option in the following Select form has been chosen....For instance if "Putaway" is chosen it needs to email...
1
by: Will | last post by:
I have a combo box on a form which is based on table tblMachine. On that combo box I have four columns visible MachineNumber, description, location and type. The bound column is the MachineNumber...
8
by: Lyn | last post by:
Hi, Can anyone tell me how the initial value displayed in Combo Box is determined when a form is opened? I am loading the dropdown from one field ("CategoryName") of a table, with "ORDER BY ". ...
1
by: laredotornado | last post by:
Hi, I'm using PHP 4.4.4 on Apache 2 on Fedora Core 5. PHP was installed using Apache's apxs and the php library was installed to /usr/local/php. However, when I set my "error_reporting"...
12
by: Doug | last post by:
Hi, I learned a little about the model view presenter pattern at a conference this last week and am experimenting with it. It's working pretty well but I have a question. I am trying to use...
1
by: The.Daryl.Lu | last post by:
Hi, two parts to my problem if someone can help address either one or both: 1. I want to SELECT everything in the table if it matches the criteria when the query button is pressed (this is just...
4
by: banderson | last post by:
Hello amazing vba writers, I am trying to make a combo box return a value based on a combo box selection. I have tried a number of the codes posted here and am still having problems. I think it is...
7
by: Orv | last post by:
I have a "Yes/No" combo box (set to required) and I want the focus to shift to differnet controls (on the same form) based on the selection of "Yes" or "No". Would this have to be placed on the...
6
by: David Wright | last post by:
Hello Folks I am using Microsoft Access 2000 I would be grateful if someone could help me with “Dlookup”. I tried various methods of writing Dlookup and various events to trigger it, none of...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

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.