By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,586 Members | 1,877 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,586 IT Pros & Developers. It's quick & easy.

Force list box to load in form with no items selected?

P: n/a
e
I have a form which includes a list box populated with items from a
query. When a user double clicks on a row in the list box, each
column item is put into a specific text box.

The problem right now is that a row is already selected, and the items
put into the text boxes, for all records that have been entered using
the form. I don't want any row selected when I create a new record.
The other problem right now is that if I select a given row in one
record, the same value is set for all subsequent records.

I already have one list box filling in text boxes in the same form and
it works fine - nothing is put into the text boxes until something is
double clicked in the list box. (This list box is based on a
different query than the one described above.) I've compared the
properties of each list box, quadruple-checked the code for the double
click event procedure, and checked the list box properties again, but
can't figure out how to force the list box NOT to select an item and
fill in the adjoining fields until a selection is made.

Any ideas?
Oct 28 '08 #1
Share this Question
Share on Google+
3 Replies


P: n/a
e wrote:
I have a form which includes a list box populated with items from a
query. When a user double clicks on a row in the list box, each
column item is put into a specific text box.

The problem right now is that a row is already selected, and the items
put into the text boxes, for all records that have been entered using
the form. I don't want any row selected when I create a new record.
The other problem right now is that if I select a given row in one
record, the same value is set for all subsequent records.

I already have one list box filling in text boxes in the same form and
it works fine - nothing is put into the text boxes until something is
double clicked in the list box. (This list box is based on a
different query than the one described above.) I've compared the
properties of each list box, quadruple-checked the code for the double
click event procedure, and checked the list box properties again, but
can't figure out how to force the list box NOT to select an item and
fill in the adjoining fields until a selection is made.

Any ideas?
If I understand your situation, I'd dbl-click, fill in the data, set
focus to some other field, and then disable the list box. I'd have a
Save and Cancel button and when pressed enable the listbox and set focus
back to it.
Oct 28 '08 #2

P: n/a
It sounds like the list box is bound to an underlying control.
the thing you need to do here, is have it so that it is not bound to
any control, this will mean that it doesn't store any value, and when
you open the form, it has no value either.

Please advise if I am pointing you in the right direction.
Oct 28 '08 #3

P: n/a
Can you post your on Double click code?
Oct 30 '08 #4

This discussion thread is closed

Replies have been disabled for this discussion.