Saving records inside of FOR / NEXT loops

ogg13

Registered User.
Local time
Yesterday, 20:06
Joined
Jan 30, 2007
Messages
49
I wish to have a loop that saves a record each time the loop iterates. Below is the code that I attempted. After debugging, I was faced with a message stating that I cannot use the SaveRecord command at this time.

Is there any other way to attempt what im trying to do here? (Basically allow the user to enter a number of techs that worked on a project and save a record with each of the techs ID via input boxes.)

Sorry for the formatting below, thanks!

intTechs = InputBox("How many technicians worked on this SR?", "RFIT Stats Database - Inquiry")
For intloop = 1 To intTechs
strTemp = InputBox("Please enter the ID of technician #" & intloop, "RFIT Stats Database - Inquiry")
txtRadioNumber = strTemp
DoCmd.DoMenuItem acFormBar, acRecordsMenu, acSaveRecord, , acMenuVer70
Next intloop
 
Why not just create a MainForm SubForm situation and let the user add as many as they want to the SubForm?
 
Good question. Im a noobie with homegrown experience 8)

Ill go ahead and look into subforms. Thanks.
 
I think you will find it a better solution but post back if you still have questions.
 

Users who are viewing this thread

Back
Top Bottom