How to: Enable a control that is currently disabled???

  • Thread starter Thread starter Weeble
  • Start date Start date
W

Weeble

I have a form with controls that are disabled by default. The form is used to
display part information. However, if the form calling this form contains a
part number not already in the system, I would like to enable all of the
controls so the needed information can be entered for this new part number.
I've looked at the Enable property but can not figure out the syntax. Please
help.

Thanks.
 
I have a form with controls that are disabled by default. The form is used to
display part information. However, if the form calling this form containsa
part number not already in the system, I would like to enable all of the
controls so the needed information can be entered for this new part number.
I've looked at the Enable property but can not figure out the syntax. Please
help.

Thanks.

Could you please explain what you mean by "the form calling this form"?
 
My company is re-time studying the various jobs we do for a customer. I am
creating a system for entering the study data & for quoting.

The Study form recieves the study info and then: 1) calls a personally
defined function to calculate the parts per hour; 2) opens the Quoting form,
(the part number entered on the Study form is checked against the existing
part data table); 3) finds the existing record and populates the Quoting form
if data exists - or - enters the part number only in the Quoting form if data
does not exist.

I set the Quoting form with all controls to enabled = False to protect
existing data from being altered by accident. If, however, data does not
exist, (a new job for instance,) I would like the function performing the
checks to set the enabled property to True so that the part info can be added.

I can only get the enabled property set through the VB code specifically
connected with the Quoting form and through a stand alone function. I tried
this:

[Forms]![MinOrderData]![PartNo].Enabled = True

It does not work. I do not recieve any error messages, but nothing changes
with the form either.

Thanks for helping with this.
 
I'm struggling to follow.
The Study form recieves the study info...

I'm guesing that what you really mean is that study info is entered
into TABLE(S) via the Study form. Or are you talking about something
entirely different?
and then: 1) calls a personally
defined function to calculate the parts per hour; 2) opens the Quoting form,
(the part number entered on the Study form is checked against the existing
part data table); 3) finds the existing record and populates the Quoting form
if data exists - or - enters the part number only in the Quoting form if data
does not exist.

I set the Quoting form with all controls to enabled = False...

How? Each control property is Enabled = No?
existing data from being altered by accident. If, however, data does not
exist, (a new job for instance,) I would like the function performing the
checks to set the enabled property to True so that the part info can be added.

I can only get the enabled property set through the VB code specifically
connected with the Quoting form and through a stand alone function. I tried
this:

[Forms]![MinOrderData]![PartNo].Enabled = True

What form and event did you place this in?
 
Back
Top