467,081 Members | 1,045 Online
Bytes | Developer Community
Ask Question

Home New Posts Topics Members FAQ

Post your question to a community of 467,081 developers. It's quick & easy.

how to make the top row of combo box = 1st entry

After I update a combo box, you have to click on the arrow to actually see
whats in the list.
Is there a way to have the first entry or first row be equal to the first
entry in the list?

Thanks in advance
Nov 13 '05 #1
  • viewed: 1271
Share:
2 Replies
"Danny" <da********@hotmail.com> wrote in
news:Dv*******************@news4.srv.hcvlny.cv.net :
After I update a combo box, you have to click on the arrow to
actually see whats in the list.
Is there a way to have the first entry or first row be equal
to the first entry in the list?

Thanks in advance

const x = 1 'set to bound column of listbox,
const y = 0 'desired row, one less than its actual position
Me.combo0.value = me.combo0.column(x,y)

and to preset it to the last row,

Me.Combo0.value = me.combo0.column(1,me.combo0.listcount -1)

Bob Quintal
Nov 13 '05 #2
On Sun, 30 May 2004 12:55:32 GMT, Bob Quintal <bq******@generation.net> wrote:
"Danny" <da********@hotmail.com> wrote in
news:Dv*******************@news4.srv.hcvlny.cv.ne t:
After I update a combo box, you have to click on the arrow to
actually see whats in the list.
Is there a way to have the first entry or first row be equal
to the first entry in the list?

Thanks in advance

const x = 1 'set to bound column of listbox,
const y = 0 'desired row, one less than its actual position
Me.combo0.value = me.combo0.column(x,y)

and to preset it to the last row,

Me.Combo0.value = me.combo0.column(1,me.combo0.listcount -1)


That's correct if the combo box has no column headers. If it does have column
headers, the column headers are row zero, and the first data row is row 1.
Personally, I like to make a generic function for this job that checks whether
the combo box has headers or not, and does the right thing.
Nov 13 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Ausclad | last post: by
rhitam30111985
3 posts views Thread by rhitam30111985 | last post: by
9 posts views Thread by prakashwadhwani@gmail.com | last post: by
reply views Thread by dudeja.rajat@gmail.com | last post: by
reply views Thread by dudeja.rajat@gmail.com | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.