Auto-populating Table Field
Jul 16, 2012
I know auto-populating has been asked before for forms, but I am looking to auto-populate a couple of fields in a table based on an ID Number that corresponds to another table. I realize it is not the best practice to duplicate data in a DB, however, I am using an ID card program that requires tables to populate the ID card information. My hope is to have two separate tables for 2 versions of ID cards.
The first table is called Firefighter info with fields of ID Number, First Name, Last Name, and Firefight Certs, EMS Certs, and emergency contact information. The second table is called EMS Personnel with fields of ID Number, First Name, Last Name, EMS Certs, and other fields that will be entered manually. I would like the First Name, Last Name, and EMS Certs fields to auto-populate in the EMS Personnel table when the ID Number is entered. I have a relationship already listed between the two table that links the ID Numbers in both.
The Firefighter Info contains the information for all members of the department, regardless of whether they are EMS, or strictly firefighters. The EMS personnel table contains information strictly regarding to the EMS members. Thus, the ID number you are entering into the EMS table will always correspond to an existing entry in the Firefighter Info table.
View Replies
ADVERTISEMENT
May 30, 2013
I have the following tables:
Inquiry (This is the main table I want to populate through the use of a form)
Programs
My question refers to two columns in the Inquiry Table
Program
Group
The program column is populated by a drop down menu that is linked from a programname column in the Programs table.
I I want is the Group column in the Inquiry table to autopopulate based on the selected programname (There is a group column associated in the Programs table) so the form field will be autopopulated.
What I have tried is autopopulating the form (form name is Inquiries) Field called Group by using =[Program].[Column](1) in the source code of the text box. This works well, but it then does not populate the main table.
I need to either
- Learn how to populate the main table column called Group based on the form autopopulating
or
- Learn how to autopopulate the column Group in in the table so the form will autopopulate
View 3 Replies
View Related
Feb 18, 2008
In case my other question cant be resolved, I'd like to do a work around, but dont know how to do that either.
So, I have a form (Photos) with a field (PhotoTitle) and in the form is a subform containing a continuous form a (Sales).
This form contains invoiceno, location, customer etc... but also PhotoTitle field.
I've been trying to get it to populate based on a relationship and use that data elsewhere, but cant, so I'd then like it to.. on enter (or focus) automatically populate with the value from the main form (photos), phototitle field and put it into the sales subform phototitle field.
What is the code for doing that?
Thanks!
View 9 Replies
View Related
Apr 19, 2006
Hi there,
I've been working on this issue for quite sometime. I've tried different methods, such as the DLookup function, but I think I'm doing something wrong. Let me explain what I'm trying to do:
This is a Work Order, the user will Select a Customer (Table Customer: Contains CustomerID and Customer Name, address, etc) from a drop down box. When they do this, I have another textbox which is designated for the Address. I would like the address to automatically populate. but its not quite working. I've tried it with the DLookup function (I entered it into the control source of the textbox). I entered the following syntax:
=DLookup("Address","Customer","CustID=" & cboCustId)
It keeps coming up with an error. I have no idea why.
Now this is just the first half. The second half I have a subform on the same main form, which lists the equipment they have on their site. The database has a number of customers with many equipment for each of them. How do I make sure that the subform only populates equipment associated with the Customer that was selected on the main form?
I hope someone is able to help me.
Thanks a lot!
View 3 Replies
View Related
Jun 27, 2014
I (will have) a form which a user fills in to enter new data.
I have two fields,
"Branch" and "Branch ID" (Branch ID will not be on the form, just in the table)
Branch will be fed by a combo box with seven choices. I would like it so that when "Branch" is populated it autopopulates Branch ID with a code which relates to the branch, so for example
BRANCH BRANCH ID
Braintree BRA
Colchester COL
View 4 Replies
View Related
Nov 20, 2013
I actually have two questions.
1. I was reviewing the Access 10 commandments and I wonder why using "lookup" is evil?
2. I am working on a db which contains approximately 14 tables. One is tblMaterialslist which contains the following fields:
ID - Autonumber
PartDescription - ShortText
PartCost - Currency
Size - ShortText
Additionally, I have a form in which I would like the "PartCost" field to auto populate when the "PartDescription" field is entered.
View 4 Replies
View Related
May 5, 2008
Sorry for posting into another thread about this, but here's my problem:
Hello All. Finally getting my pride out of the way and asking this. I've searched and this is the closest question pertaining to the problem I'm having. I have created a form to populate a table in Access. I've created Lookup fields for parts of the table that will get data from another table/tables. I want a certain part of the form to auto-populate data based off of the last name I put in the initial Drop-down box. Say, I have a person with a last name (and there are several with the same last names), I want the remainder of that line in the form/report to populate with his/her data needed for the form letter. Unfortunately right now, I have it where we have to select each from a drop down menu, for both last names, first names and other data needed. I've tore my brain up trying to figure out how to link the data in each one of the combo boxes to the first combo box. Any help would be appreciated. These are driving me nuts as I should be able to figure this out and it's just escaping my vision I guess. Thanks in advance for the help.
View 2 Replies
View Related
Sep 8, 2011
I am trying to create a form from questions listed in a table, add a yes/no column to it and then have it auto populate a data sheet with the question and the answer. how I can have the datasheet autopopulated?
View 1 Replies
View Related
Nov 15, 2013
I have two tables, "Membership" and "Class." The Class table has a class ID, class name, and cost of the class.
In the Membership table, I have a field to accept a class ID that is entered by a user. I also have a column called Tuition. When the user enters a classID in the Membership table, I would like the dollar amount associated with that classID to automatically appear in the field called Tuition in the Membership table.
I tried the LOOKUP data type and calculated fields, but no luck. I know that DLOOKUP can be used on forms, but I don't see how it can be used directly with tables.
Is this even possible?
View 1 Replies
View Related
Apr 26, 2012
I have a combobox on my form with fields related to it (ie. when an option is chosen in the drop-down, the next two fields are also populated with data based on the selection made - I know this is duplication of data, it's just the way the 'powers that be' wanted it. I'm changing it in my next version of the database!)
The two fields that are populated as a result of the selection in the combobox are migrating into the related table fine, but the actual selection in the combobox isn't - it's showing up as blank in each new record in the table.
View 4 Replies
View Related
Sep 15, 2013
I've been trying to populate a field in a form with information, but only if the field is blank.
What I am trying to do is this.
I have a continuous form displaying all of our principals, however when our principals are on leave I want to populate the field with the "acting principal". I have set it up so the field grabs the acting principal first but it is blank for several schools. For these schools where there there is no "acting principal" I want it to grab the substantive principal automatically and populate the field.
I have tried Is Null, Is Not Null, NZ, IF, Where and Then statements but to no avail.
View 10 Replies
View Related
Aug 8, 2005
I’m fairly new to Access so I hope I can get the terminology correct. I’ve been working on creating a database which has a one to many relationship. With the help of the people in the table forum, I do have that working correctly, and even have a form and sub form where the data can be successfully input.
In short, I have a main item table to track my widgets. I have a reference or look up table of colors. Third, I have a relationship table that manages the one to many relationship. My main input form has all the fields that need to be plugged into the primary table. The Sub-Form is setup for continuous forms which allow me to input as many colors as I need. Again, this all works great.
Now, to go to the next level. There are times when I want to select many (lets say 8) different colors to my widgets (kept in the primary database and form). To select each all 8 colors each time is somewhat of a pain. It is my hope and intent to create a button on my sub form that would populate my subform with the static 8 colors that I want, thus bringing me down to a single click instead of 16. (1 for the drop down, 1 to select the color).
Is this at all possible? If so, can someone give me a shove in the right direction?
Structure as follows:
TblWidgets
•Widget – Text
•Value – Numeric
•Description – Memo
•Type – Text
TblColors
•Color - Text
•Description – Text
TblWidgetColorRelationship (one to many relationship)
•Widget – points to primary key in TblWidgets
•Color – points to primary key in TblColors
Thanks,
Joiry
View 5 Replies
View Related
Jan 15, 2015
I am creating a database to keep up with the expenses for my art business. I have a table for Vendors with a field (Mileage) for one-way mileage that I enter manually (EX: 11.8 miles). Then I have a calculated field that basically just multiplies the Mileage field times two to get total mileage to and from my house to vendor location. (Total Miles) {The reason I want to do this this way right now is because I didn't keep up with my mileage this year and I am having to look up the distance from my home to each location)
Then I have a "supplies" table where I show the date, the vendor, the item, cost, etc, and I want to add a Total Mileage field based on the calculated Total Miles field in the Vendors table that will automatically populate based on the vendor of each transaction. I just can't remember how to make this work and I know just enough SQL to be dangerous.
View 2 Replies
View Related
Jul 24, 2012
I have an infopath form, which people in my company can fill out to order parts. The form is linked to an Access database. The primary keys for the database are the Order Number and the Line Number (where the specific part info is in the system). The form also takes info about who entered the order, when they entered it, etc.
My problem is that while the form will be used for only one order, it may be used to order multiple parts. So the infopath form has a repeating section with a table where they can enter multiple line numbers and part names, etc.If I use the form to enter just one part, everything works great. But when I use the repeating section to add multiple parts, the information specific to the repeating section is added to the database but the rest of the information (who entered, when the entered, etc) isn't.
My intial idea was that since the first part is entered correctly and the subsequent parts are missing some information which is already in another line in the database. Maybe if there was a way to pull the information from another line into the lines with missing info within access would solve my problem. So basically automatically populating the rows with matching Order Numbers with the information that is missing.
View 7 Replies
View Related
Apr 13, 2013
I'm using a combo box to pull data from a table to auto populate the fields on my form. But for some reason, it stops inserting the data after city (column(6) and I can't figure out what's going on. When I run the query the data is there, if I change the order of the columns, the data shows. Here's the code:
Me.txtadjusterfname.Value = Me.cboAdjusterlkp.Column(0)
Me.txtadjusterlname.Value = Me.cboAdjusterlkp.Column(1)
Me.txtadjustertitle.Value = Me.cboAdjusterlkp.Column(2)
Me.txtadjustertype.Value = Me.cboAdjusterlkp.Column(3)
Me.txtadjustercompany.Value = Me.cboAdjusterlkp.Column(4)
Me.txtadjusteraddress.Value = Me.cboAdjusterlkp.Column(5)
Me.txtadjustercity.Value = Me.cboAdjusterlkp.Column(6)
Me.txtadjusterstate.Value = Me.cboAdjusterlkp.Column(7)
View 1 Replies
View Related
Mar 31, 2014
how to auto populate list box based on two dependent combo boxes.
View 9 Replies
View Related
Feb 28, 2013
Within my table if Field 1 has an answer of Self (from drop down), then, I would like Fields 6-12 to auto populate; however, if Field 1 does not have an answer of Self, then leave Fields 6-12 blank.
I am not quite sure how to lay this out. I am using Access 2010.
View 8 Replies
View Related
Mar 4, 2008
I'm creating a database that keeps a track of questions and scores.
The questions in the database need to be dynamic and are changed frequently.
I have a scorecard table which keeps a record of scores and the applicable question at the time the record was saved. I need to do this because in 6 months time we may want to provide feedback. As the question may have changed we need to be able to refer back to what the question was.
I want the question field in my scorecard table to populate with the value in my question table.
I have tried a number of things including setting the question field in the scorecard table to a lookup based on the following query:
SELECT tblQ1.Q1
FROM tblQ1;
This works however only as a list or combo box. I don't want the user to have to select the question. I want it to auto populate, is this possible?
View 1 Replies
View Related
Mar 6, 2006
Please help
I have 2 tables:-
1 Master Input Table.
1 Job Lookup table - (contains Job Number and Name)
When in-putting job details into the Master Input table i would like to enter the job number only and have the job name appear automatically without running a query, much the same as a 'vLookup' command in excel.
Is this possible?
Can anyone help?
View 3 Replies
View Related
Feb 12, 2008
I have a table with order numbers I would like to auto increment the number part of the order when new record is added to the table.
My order numbers looks like this:
UZSK-0001
UZSK-0002
UZSK-0003
UZSK-0002
How to make access increment the number part?
View 14 Replies
View Related
Sep 12, 2012
So I have this query that runs ....
Code:
Expr1: Left([EVENT_TBL].[EVENT_TYPE],3) & Left([EVENT_TBL].[EVENT],4) & Format([EVENT_TBL].[EVENT_DATE],"ddmmyyyy")
How can I get the result into the [EVENT_TBL].[EVENTTYPDTE_ID] Field?
View 3 Replies
View Related
Jan 21, 2011
I am working on Access 2007.
I have two separate tables (called inventory and job log) and they have a few of the same field items (number, name, style 1, style 2, and area).
I would like the job log table to autofill the name, style 1, style 2, and area when you type in the number when logging a new job (pulling this information from the inventory table)..
View 3 Replies
View Related
Feb 15, 2015
I have a table ([AllNames]) that a field ([Past_Employers]) is being auto-populated, and I don't want it to.
[Past_Employers] population is setup form a form, which references a separate table of employer names [Employers].
If I enter a new record directly in the [AllNames] table the [Past_Employers] field populates.
[Past_Employers] is a multi-value field (yes ugh - I know!!!) and is not required.
View 4 Replies
View Related
Jul 29, 2015
Currently I have a form with these variables
- Assets
- Shifts
- Machine Offline Date
- Machine Offline Time
- Machine Online Date
- Machine Online Time
In the Asset Table I have recorded on each asset the number of shifts it operates for as well as starting / finishing time of those shift. e.g. 2 shift asset will start at 7:00AM finish at 11:00PM
or 3 shifts asset will start at 7:00AM finish at 6:59AM
Now I have 82 assets in the factory and 20% of those machines run 3 shifts. Each shift is 8 hrs.
What I have already done is allocate shifts per asset e.g.
when I pick Asset (a) in the Asset combo box, in the shift box it will automatically generate 2 or 3 dependant on what I have set.
If an asset runs for 2 shifts, it would mean that, that asset is operational/running from 0700 - 2300 or 7:00am - 11:PM
also if an asset runs for 3 shifts it would mean that, that asset is operational/running from 0700 - 0700 or 7:00AM - 7:00AM
These are the scenarios that is entered through a "Form"
Scenario A: Machine (a) breaks down at 1700/5:00PM on the 10/7/15 and was back online at 12:30 on 11/7/15, This machine runs for 3 shifts which would mean in the "Breakdown Downtime" the result should be 19.5 hrs
Scenario B: Machine (b) breaks down at 1900/7:00PM on the 10/7/15 and was back online at 10:00AM on 12/7/15, this machine runs for 2 shifts which would mean in the "Breakdown Downtime" the result would be 23 hrs.
I would like to make this an automatic calculation, Is this possible?
Please note I am not after a "Query", I need this calculation in the main Database table named "Tbl_MaintenanceDATA".
I understand this is not the norm and many have suggested against this, however for the purpose of what I need, it needs to be in the main table with all the other data.
Here are some snip it
snipit2.png
snipit.png
View 5 Replies
View Related
May 7, 2014
I have been away for Access for a long time and having issue with making a query. I have 3 tables. "tablEmployee" has employee ID, first name, last name and sizer ID. "tblproduct" has product ID, Description and rate. I made a new table called tbldata which has date, product code, product description, product rate,employee id, employee sizer id, and lbs. I want a query when I enter the product id in tbldata, query auto fill the product description and rate. also same as employee.
View 3 Replies
View Related
Jun 22, 2007
Is this possible, and how can I do it?
Adding a second auto number field to current table and auto numbering current entries?
I need to combine some records from the same order number that currently have detailed names. I'm trying to simplify them, but I can't because it creates duplicate records.
View 2 Replies
View Related