Andy Lacey
andy at minstersystems.co.uk
Mon Jan 8 16:40:33 CST 2007
You can do it with a loop Steve. Something like Function SubFormAllowEdits(blnOnOrOff As Boolean) Dim ctl as control For each ctl in me.controls if ctl.ControlType = acSubform then ctl.Form.AllowEdits=blnOnOrOff end if Next End Function Not tested but shouldn't be far off (I hope). -- Andy Lacey http://www.minstersystems.co.uk > -----Original Message----- > From: accessd-bounces at databaseadvisors.com > [mailto:accessd-bounces at databaseadvisors.com] On Behalf Of Steve Zayko > Sent: 08 January 2007 22:33 > To: Access Developers discussion and problem solving > Subject: [AccessD] Allow Edits > > > I have a control that turns on and off the "AllowEdits" > property on a form. This form also have several sub-forms > embedded on it. > > If I turn off the AllowEdits property on the main form, then > must I also do the same for each and every sub-form? > > Thanks > > -Z > > Stephen R. Zayko PE > SECOR International Inc > 2321 Club Meridian Drive Ste E > Okemos, MI 48864 > > (517) 349-9499 ext 224 > (517) 204-5136 (c) > > -- > AccessD mailing list > AccessD at databaseadvisors.com > http://databaseadvisors.com/mailman/listinfo/accessd > Website: http://www.databaseadvisors.com > >