Temp Field

  • Thread starter Thread starter Angel_G
  • Start date Start date
A

Angel_G

Hi there!
Can anyone help with the following?
I have a Form that has a combo box (In the form header) that when a part
number in the combo box is selected then the detail in the form displays all
the specs associated with that part number. What I want is to have a field
available for each spec so that I can write the results for each spec. Then,
I can run an append query that will capture all the specs and the data that
I typed in the temp fields and write it to the Results table. Is this
possible?

The query should look like this:
Combo Box = 4X7 Plastic Bag
Air Min 10PSI Max 40PSI Results______
Thickness Min 10MIL Max 30MIL Results______

Different Item

Combo Box = 7" Wire
Diameter Min 40 Max 65 Results______
Pull Strength Min 8Lbs Max 16Lbs Results______
Length Min 6.95" Max7.15" Results_____

Notice that the results change and I want an available field for each of the
specs (That will grow as the specs grow).
Here is my Query in case needed.

SELECT tblRMSpecs.*
FROM tblRMSpecs
WHERE (((tblRMSpecs.PartNo)=[Forms]![Form]![PartNo]));

Thank you so much!
 
Angel_G said:
Hi there!
Can anyone help with the following?
I have a Form that has a combo box (In the form header) that when a part
number in the combo box is selected then the detail in the form displays all
the specs associated with that part number. What I want is to have a field
available for each spec so that I can write the results for each spec. Then,
I can run an append query that will capture all the specs and the data that
I typed in the temp fields and write it to the Results table. Is this
possible?

The query should look like this:
Combo Box = 4X7 Plastic Bag
Air Min 10PSI Max 40PSI Results______
Thickness Min 10MIL Max 30MIL Results______

Different Item

Combo Box = 7" Wire
Diameter Min 40 Max 65 Results______
Pull Strength Min 8Lbs Max 16Lbs Results______
Length Min 6.95" Max7.15" Results_____

Notice that the results change and I want an available field for each of the
specs (That will grow as the specs grow).
Here is my Query in case needed.

SELECT tblRMSpecs?.*
FROM tblRMSpecs
WHERE (((tblRMSpecs.PartNo)=[Forms]![Form]![PartNo]));

Thank you so much!
One way would be to put a subform in the form footer that is bound to the
results table. After a part number is selected in the combo box, code in the
combo box afterupdate events adds new blank records to the results table
which is then displayed in the subform. Add the new data in the subform. When
the main form is closed or a new part number is selected, code (or a delete
query) runs to delete blank records in the results table.

Another way would be to add a new field to "tblRMSpecs"; it would be
displayed in the details section to add the new results. Then use code to add
the new data to the results table.

What you will need to do is add a field ("Results") to tblRMSpecs.
Then (in code - a button?) loop thru the the form RecordSet (or
RecordsetClone)

'--- begin AIR CODE ------
Dim rst as DAO.Recordset
Dim rs as DAO.Recodrset

Set rst = Me.Recordset
Set rs = docmd.Openrecordset("tblResults")
rst.moveFirst
do while not rst.eof
If rst!Results is not null
add new record to tblResults
rs.AddNew
 
Back
Top