Take out items from Combobox once chosen (1 Viewer)

capsula4

Registered User.
Local time
Yesterday, 16:46
Joined
Jan 3, 2008
Messages
122
I have something like this:

tblDays: DAY ID, BANK ID
tlkp: BANK ID, BANK NAME

And on tblDay I have a form that displays a combobox for Banks.

I would like that once you choose a bank, that specific bank is out from the combobox.

I tried the followin:

Created a query that returns:

BANK NAME,BANK ID,
Where BANK ID <> [tblDays]![BANK ID]

And use this query as the source query for the combobox. The problem here is that it doesn't recognize "[tblDays]![BANK ID]": it popups a window sayin to enter a parameter for "[tblDays]![BANK ID]" but I never created any parameter... so I'm guessing that what I'm trying to do is simply impossible?
 

jdraw

Super Moderator
Staff member
Local time
Yesterday, 19:46
Joined
Jan 23, 2006
Messages
15,393
I have something like this:

tblDays: DAY ID, BANK ID
tlkp: BANK ID, BANK NAME

And on tblDay I have a form that displays a combobox for Banks.

I would like that once you choose a bank, that specific bank is out from the combobox.

I tried the followin:

Created a query that returns:

BANK NAME,BANK ID,
Where BANK ID <> [tblDays]![BANK ID]

And use this query as the source query for the combobox. The problem here is that it doesn't recognize "[tblDays]![BANK ID]": it popups a window sayin to enter a parameter for "[tblDays]![BANK ID]" but I never created any parameter... so I'm guessing that what I'm trying to do is simply impossible?

What exactly do you mean by "once you choose a bank, that specific bank is out from the combobox."

If you move the selection somewhere, then you could rerun the query that fills the combo box, but this time ignore the value that was previously selected.

If you don't do anything with the selected value, the query doesn't know that anything has changed.
 

capsula4

Registered User.
Local time
Yesterday, 16:46
Joined
Jan 3, 2008
Messages
122
What exactly do you mean by "once you choose a bank, that specific bank is out from the combobox."

If you move the selection somewhere, then you could rerun the query that fills the combo box, but this time ignore the value that was previously selected.

If you don't do anything with the selected value, the query doesn't know that anything has changed.

Yeah, I mean something like what I think you understood.

You have let's say a combo with 7 banks...

I select one of em for a specific registry...

Then, when i create a new registry, I would like the combo just to show up 6 banks in the combo, the ones that haven't been used yet.
 

Users who are viewing this thread

Top Bottom