SgiGod
February 28th, 2000, 11:09 AM
How can I clear all the fealds on a form if the
feilds are linked to a Data Base
Thanks in Advance
Donny S.
feilds are linked to a Data Base
Thanks in Advance
Donny S.
|
Click to See Complete Forum and Search --> : Clear Feilds SgiGod February 28th, 2000, 11:09 AM How can I clear all the fealds on a form if the feilds are linked to a Data Base Thanks in Advance Donny S. February 28th, 2000, 11:44 AM Try this: private Sub Command1_Click() Dim ctl as Control for Each ctl In Form1.Controls If TypeOf ctl is TextBox then ctl.Text = "" End If next End Sub Vlad Johnny101 February 28th, 2000, 12:24 PM You could also call the AddNew method of the data control you are using. That should clear all the linked controls and allow for new info to be entered. Then when you want to save that info, you would call the Update method of the data control. HTH, John John Pirkey MCSD www.ShallowWaterSystems.com codeguru.com
Copyright Internet.com Inc., All Rights Reserved. |