Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Multiple Data Entry

Status
Not open for further replies.

achiola

MIS
Apr 26, 2001
44
US
Hi All,
I am really having a hard time with this one. I have created a form with various data fields. Once the data is entered it is submitted to a table. That works fine. However, most of the data is similiar with each entry and I am looking for a way to create a form that allows multiple data entry in the same field while still bringing that information over to the table to be called up again. Can anyone help, I will try any suggestion because modifying this form is important for our company's project goals.

Nino
 
Right click on the field and change it to a combo box.
Then double click the field and select the row source and select the table or query that your form is based on.

Add the field name and sort it alphabetically. right click up by the table and change the properties of the query to list "Unique Values". You don't want your list to have "MICHIGAN" in it 1000's of times.

This way you can either add new data or if you hit the dropdown arrow you can lookup any of the data that was previously entered under this particular field.

If you need a sample let me know - repost and I will send you one.

kramerica
 
Kramerica

I want to make sure I explain this correctly. Here is my simple sample data:

Date: 6/15/01
Product: Window, Door, Siding
Item #: 55555

I would like to enter 3 different Products on the form at once and get reflected in the table. So the table would list:

Date: 6/15/01 Date: 6/15/01 Date: 6/15/01
Product: Window Product: Door Product: Siding
Item#: 55555 Item#: 55555 Item#: 55555

I hope this makes the picture clearer
 
Kramerica

I want to make sure I explain this correctly. Here is my simple sample data:

Date: 6/15/01
Product: Window, Door, Siding
Item #: 55555

I would like to enter 3 different Products on the form at once and get reflected in the table. So the table would list:

Date: 6/15/01 Date: 6/15/01 Date: 6/15/01
Product: Window Product: Door Product: Siding
Item#: 55555 Item#: 55555 Item#: 55555

I hope this makes the picture clearer
 
Hi, Nino!

There is one way what can solve your problem.
Create continuous form (1) or subform (2). On form's header or footer (1) or on main form (2) create two unbound text boxes e.g. txtDate and txtItemNo for entering of date and Item#. On detail section create all needed bound text boxes. Make bound textboxes Date and ItemNo invisible.

Write
codes for continuous form:

Private Sub Form_BeforeUpdate(Cancel As Integer)
me.Date = me.txtDate
me.ItemNo = me.txtItemNo
End Sub

or

Private Sub Product_AfterUpdate()
me.Date = me.txtDate
me.ItemNo = me.txtItemNo
End Sub

or
codes for continuous subform:

Private Sub Form_BeforeUpdate(Cancel As Integer)
me.Date = forms("MainFormName")("txtDate")
me.ItemNo = forms("MainFormName")("txtItemNo")
End Sub

Also you can use syntax
forms!MainFormName!txtDate

or

Private Sub Product_AfterUpdate()
me.Date = forms("MainFormName")("txtDate")
me.ItemNo = forms("MainFormName")("txtItemNo")
End Sub


Doun't forget validation of data of unbound textboxes!

I hope its will little help you.

Regards!
Aivars
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top