error 2424 message

E

EVPLS

Hi,

My database includes a form for rentals of the department-owned car by
employees. This form has a combobox to select the hirer. The NotInList event
procedure calls to open in Dialog mode the form to enter a new employee's
master data, while the rental form goes invisible. The master data form's
cmdSave_Click event procedure hides the form.

While the rental form is still invisible, its hirer combo NotInList
procedure is then to read from the master data form's key field. That's when
error 2424 comes in.

The direct window provides this:

? Forms(1).Name, Forms(conNewHirerData).Name
frmG100Employees frmG100Employees

-- So the form is open, whether identified via its index or by a constant.

? Forms(conNewHirerData).Controls("txtContact").name
txtContact

? forms(1).txtcontact.name
txtContact

-- So basically the textbox should be there, shouldn't it?

"? Forms(conNewHirerData).Controls("txtContact").value", however, returns
the error.

Neither the rental nor the master data forms are pop-up or subforms.

What am I overlooking? Appreciate very much any hints.
 
E

EVPLS

Hi,

problem solved. Had "trash" in the txtContact field (displayed error value).
After correction of source, procedure works fine. Thanks to anyone who may
have taken a look at the question already.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top