I need an IF then else statement so if the origin value = 0 the record is not added to the table. This is the code I have.
SourceSet.AddNew
SourceSet!Employee_Name = Text137.Value
SourceSet!Stop1 = Combo0.Value
SourceSet!Origin = Combo8.Value
SourceSet!Stop2 = Combo2.Value
SourceSet!Stop3 = Combo4.Value
SourceSet!Stop4 = Combo6.Value
SourceSet!Stop1_dist = Text10.Value
SourceSet!Stop2_dist = Text13.Value
SourceSet!Stop3_dist = Text14.Value
SourceSet!Stop4_dist = Text15.Value
SourceSet!Datefield = ActiveXCtl22.Value
SourceSet.Update
SourceSet.AddNew
SourceSet!Employee_Name = Text137.Value
SourceSet!Datefield = ActiveXCtl65.Value
SourceSet!Origin = Combo54.Value
SourceSet!Stop1 = Combo46.Value
SourceSet!Stop2 = Combo48.Value
SourceSet!Stop3 = Combo50.Value
SourceSet!Stop4 = Combo52.Value
SourceSet!Stop1_dist = Text56.Value
SourceSet!Stop2_dist = Text58.Value
SourceSet!Stop3_dist = Text59.Value
SourceSet!Stop4_dist = Text60.Value
SourceSet.Update
SourceSet.AddNew
SourceSet!Employee_Name = Text137.Value
SourceSet!Stop1 = Combo0.Value
SourceSet!Origin = Combo8.Value
SourceSet!Stop2 = Combo2.Value
SourceSet!Stop3 = Combo4.Value
SourceSet!Stop4 = Combo6.Value
SourceSet!Stop1_dist = Text10.Value
SourceSet!Stop2_dist = Text13.Value
SourceSet!Stop3_dist = Text14.Value
SourceSet!Stop4_dist = Text15.Value
SourceSet!Datefield = ActiveXCtl22.Value
SourceSet.Update
SourceSet.AddNew
SourceSet!Employee_Name = Text137.Value
SourceSet!Datefield = ActiveXCtl65.Value
SourceSet!Origin = Combo54.Value
SourceSet!Stop1 = Combo46.Value
SourceSet!Stop2 = Combo48.Value
SourceSet!Stop3 = Combo50.Value
SourceSet!Stop4 = Combo52.Value
SourceSet!Stop1_dist = Text56.Value
SourceSet!Stop2_dist = Text58.Value
SourceSet!Stop3_dist = Text59.Value
SourceSet!Stop4_dist = Text60.Value
SourceSet.Update