Michael R Mattys
mmattys at rochester.rr.com
Mon Jun 4 19:02:54 CDT 2007
Dan, You could simplify to this: Public Sub TEST(cbo as ComboBox) '-- if things aren't right cbo.SetFocus End Sub Michael R. Mattys MapPoint & Access Dev www.mattysconsulting.com ----- Original Message ----- From: "Dan Waters" <dwaters at usinternet.com> To: "'Access Developers discussion and problem solving'" <accessd at databaseadvisors.com> Sent: Monday, June 04, 2007 5:32 PM Subject: [AccessD] Set Focus on Form from Standard Module > Arrrgh! Syntax! > > I have a procedure, called by different forms as a validation check of > sorts. > > Public Sub TEST(cboPerson as ComboBox, frm as Form) > > '-- if things aren't right > frm.cboPerson.SetFocus > > End Sub > > But of course this doesn't work. What is the syntax? Am I passing the > correct objects to the procedure? > > > Thanks! > Dan > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com