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 sizbut on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Continuous subform with data entry

Status
Not open for further replies.

dolfin13

Programmer
Jun 29, 2005
22
US
I have a New Call form that creates a new Activity and has a subform to enter in details related to this activity.

I'm trying to get the subform to list active opportunities and be able to enter details for each opportunity for the particular Activity at hand.


tblDetails
-----------
ID Auto
ActivityID Number (related to activity table)
Opportunity Number (related to opportunity table)
Details memo
-----------

How can I have multiple new records (based on how many active opportunities there are for the given company) ready for details to be input but the opportunities already there and waiting?

ex.
Contactperson phone
companyname date

subform (companyname has three active opportunities)
-----------
Opportunity Name Details
-----------------------------------------------------
Opp1 (empty for data entry)
Opp2 (empty for data entry)
Opp3 (empty for data entry)


I believe I am thinking about this the wrong way and am having trouble thinking through it, any help would be appreciated.
 
If you know how many opportunities there are for each company, you could use an append query that adds a record for one opportunity and use code to run the query the appropriate number of times:

Code:
Dim IntJ as integer

For IntJ = 1 to NumberOfOpps
docmd.OpenQuery "myAppendQuery"
Next IntJ

HTH



John

Use what you have,
Learn what you can,
Create what you need.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top