populating an unbound combobox

  • Thread starter Thread starter Chris
  • Start date Start date
C

Chris

Hello All, I have an unbound form and on my unbound form I have an unbound
combobox. The combobox recordsource is a table of client types
(tblClientType). I would like the combobox to have a default value to equal
"Ordinary" which has the pk 1.

tblClientType - CTID (AutoNum) (pk), client type (text)

1 Normal
2 Old
3 New
4 Returning

How do I do this?
 
Chris said:
Hello All, I have an unbound form and on my unbound form I have an
unbound
combobox. The combobox recordsource is a table of client types
(tblClientType). I would like the combobox to have a default value to
equal
"Ordinary" which has the pk 1.

tblClientType - CTID (AutoNum) (pk), client type (text)

1 Normal
2 Old
3 New
4 Returning

How do I do this?

Assuming that Ordinary/Normal is a typo set the default value of the
ComboBox to 1.
 
I'm 1000% sure I've done that before and it's not worked. Now I'm very
confused that it is working

Thanks alot
 
I've remembered the original problem now. When I add a record I have the
combobox reset by a function. I've tried setting the cbobox to =1 then
requerying but I still can't get it to work.

Any idea's
 
Chris said:
I've remembered the original problem now. When I add a record I have
the combobox reset by a function. I've tried setting the cbobox to
=1 then requerying but I still can't get it to work.

Any idea's

If you set the value why are you also requerying it? A requery will likely set
the entry back to Null. Have you tried doing the Requery before you set the
value? If the RowSource does not change there should not be any need to requery
anyway.
 

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

Back
Top