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

Add from combo box to continous subform

Status
Not open for further replies.

nycbigapple

Technical User
Apr 4, 2006
33
0
0
US
Hi, I have main form that has an unbound combox and an command button, there is also continuous subform.

What I am trying to do is select an item from the combobox and then click on the cmd button
to add this item into the subform list.

This is what I have so far in my command button click event
Code:
Me.psfrmEmployeeTraining.SetFocus
DoCmd.RunCommand acCmdRecordsGoToNew
Me.psfrmEmployeeTraining!ControlName.Value = Me.cboTrainingRequirement.Value
 
To get you started you will need to add the new value to the record sorce for the continous subform. Then requiry the continous subform for the value to appear.
 
why do you do it so complcated just on the combox box afterupdate event (or you can use a command buttonn) type this up

SubformName.FieldName = Combo1

or if you have a couple of columns in the combo box just do this

SubformName.FieldName = Combo1.column (0) 'For the fisrt column in the Cbo
SubformName.FieldName2 = Combo1.column (1)
SubformName.FieldName3 = Combo1.column (2)

and so on and on


I will try my best to help others so will others do!!!!!
IGPCS
Brooklyn, NY
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top