M manners Registered User. Local time Today, 21:27 Joined Oct 10, 2001 Messages 16 Oct 12, 2001 #1 Can anyone help me to create a "Clear Fields" Button on a form please?
aqif Registered User. Local time Today, 21:27 Joined Jul 9, 2001 Messages 158 Oct 12, 2001 #2 Write the code like: Me.Txtbox1=Null Me.Txtbox2=Null I believe that u've to clear each field by mentioning the name of every field in the code. Cheers! Aqif
Write the code like: Me.Txtbox1=Null Me.Txtbox2=Null I believe that u've to clear each field by mentioning the name of every field in the code. Cheers! Aqif
SteveA Registered User. Local time Tomorrow, 08:27 Joined Oct 8, 2001 Messages 126 Oct 12, 2001 #3 You could also write code to loop through the controls collection. ie Dim ctl as control For each ctl in Me.Controls If ctl.ControlType = acTextBox then ctl.Value = Null end if Next ctl Cheers, SteveA
You could also write code to loop through the controls collection. ie Dim ctl as control For each ctl in Me.Controls If ctl.ControlType = acTextBox then ctl.Value = Null end if Next ctl Cheers, SteveA