#1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default ComboBox


Dear Friends

When we select a range for combobox. The Selected range shows every row
in the combobox, either there is data in a row or not. How can we show
only filled data rows in a range for ComboBox.

sub userForm_activate

comboBox1.column count = 1
ComboBox1.Rowsource= "a1:a1000"

End sub


--
Syed Haider Ali
------------------------------------------------------------------------
Syed Haider Ali's Profile: http://www.excelforum.com/member.php...o&userid=21994
View this thread: http://www.excelforum.com/showthread...hreadid=469979

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2,718
Default ComboBox

One way is to determine the range dynamically:

ComboBox1.RowSource = Range("A1", Range("A1").End(xlDown)).Address

This assumes at least two items in the list.

--
Jim
"Syed Haider Ali"
<Syed.Haider.Ali.1vry2h_1127415944.9738@excelfor um-nospam.com wrote in
message news:Syed.Haider.Ali.1vry2h_1127415944.9738@excelf orum-nospam.com...
|
| Dear Friends
|
| When we select a range for combobox. The Selected range shows every row
| in the combobox, either there is data in a row or not. How can we show
| only filled data rows in a range for ComboBox.
|
| sub userForm_activate
|
| comboBox1.column count = 1
| ComboBox1.Rowsource= "a1:a1000"
|
| End sub
|
|
| --
| Syed Haider Ali
| ------------------------------------------------------------------------
| Syed Haider Ali's Profile:
http://www.excelforum.com/member.php...o&userid=21994
| View this thread: http://www.excelforum.com/showthread...hreadid=469979
|


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default ComboBox


Thanks Jim Rech. It is working properly


--
Syed Haider Ali
------------------------------------------------------------------------
Syed Haider Ali's Profile: http://www.excelforum.com/member.php...o&userid=21994
View this thread: http://www.excelforum.com/showthread...hreadid=469979

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
fill combobox depending on selection from another combobox Adam Francis Excel Discussion (Misc queries) 2 July 24th 08 07:39 PM
How Do I Load A ComboBox RowSource From The Results Of Another ComboBox Minitman[_4_] Excel Programming 3 October 26th 04 07:58 PM
Populating combobox from another combobox David Goodall Excel Programming 1 September 12th 04 03:42 PM
Combobox Francis Ang Excel Programming 2 February 19th 04 05:31 AM
Combobox Tony G[_2_] Excel Programming 1 October 24th 03 01:53 PM


All times are GMT +1. The time now is 11:22 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"