afterupdate requery on a tabcontrol

A

Arjan

All,

I'm a bit stuck and I would appriciate it if some could help..

On a tabcontrol I have 3 comboboxes, which are depends on another combobox.
I do this with some queries and it seems i'm on the right way.

Hoever i'm not able to requery the boxes after I change the "leading"
combobox... but when I press F5 it does refresh my page and all the values in
the comboboxes are correct.

I tried to a "me!comboboxname.requery" on multiple afterupdate places (the
form, the leading combobox etc..) But I can't get it to work...

What am I doing wrong?

Thanks for helping!
Arjan
 
J

Jack Leach

Me.Comboboxname.Requery should work. Disregard the fact that they are on
tabbed controls, it doesn't matter as far as this situation is concerned.

Have you been able to verify that the queries are pulling the correct
information? I use the Me.Comboboxname.Requery method all the time for these
types of operations. It seems as though the issue might be elsewhere.

--
Jack Leach
www.tristatemachine.com

"I haven't failed, I've found ten thousand ways that don't work."
-Thomas Edison (1847-1931)
 
A

Arjan

Jack,

Now in more detail, this is what I have:

1. A combobox called: cboxdivision with rowsource: "SELECT [Division].Naam
FROM Division" together with afterupdate function: Me.cboxOSE.Requery

2. A combobox called: cboxOSE with rowsource: "queryOSE". The SQL of this
query is: SELECT Employees.Naam, Employees.Function, Employees.Division,
Employees.Active FROM Employees WHERE (((Employees.Function)="Outside Sales
Engineer") AND ((Employees.Division)=[EPMDivision]) AND
((Employees.Active)=Yes));

What I informed you before: when I press F5 the cbox does refreshes and
shows the correct outside sales engineer (corresponding to the division)..
why does my afterupdate function doesn't work? I don’t see what I’m doing
wrong, do you?

Best regards,
Arjan
 
L

Linq Adams via AccessMonster.com

Wihtout having your app in front of us it's hard to tell, but the AfterUpdate
events of controls only fire if those controls have data entered or choices
made (such as in a combobox) thru ***physical*** input.

In other words, if you type

"Jack"

into the txtFirstName textbox, and move to another control, the

txtFirstName_AfterUpdate

event fires. But if you enter the name thru code, such as

Me.txtFirstName = "Jack"

then

txtFirstName_AfterUpdate

does not fire.
 
A

Arjan Bregman

Ok, clear.

The mentioned cobox; "cboxdivision" is filled with a table and the second cobox "coboxOSE" is filled with a query. So, this is not really code but is also not manually entered as it is chosen from a dropdown list.

Does this help to determine what the problem is?

Thanks.
Arjan



Linq Adams via AccessMonster.com wrote:

Wihtout having your app in front of us it is hard to tell, but the
08-Nov-09

Wihtout having your app in front of us it is hard to tell, but the AfterUpdat
events of controls only fire if those controls have data entered or choice
made (such as in a combobox) thru ***physical*** input

In other words, if you typ

"Jack

into the txtFirstName textbox, and move to another control, th

txtFirstName_AfterUpdat

event fires. But if you enter the name thru code, such a

Me.txtFirstName = "Jack

the

txtFirstName_AfterUpdat

does not fire

-


Previous Posts In This Thread:

EggHeadCafe - Software Developer Portal of Choice
..NET Compact Framework Kill All Programs
http://www.eggheadcafe.com/tutorial...c0-6040a0f54209/net-compact-framework-ki.aspx
 

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

Top