Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 1
Default List boxes/combo boxes

I'm having trouble using lists and combo boxes. Basically,
I'm new at using them.
I want a combo box/lists to have 3 values I can select,
Yes/No/Pending. I was thinking maybe lists/combos work
like validation, where you can store the value in the
control or on the worksheet, but can't get either way to
work. I've tried tinkering with row source and column
source but no luck.

Can anyone help me please....

Thanks
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 5
Default List boxes/combo boxes

If it's a combi-box on a sheet, then the index-value for the values in the input-range is stored in the cell given as "cell-link"

So, suppose you have the input-range A1001:A1003 where you have respectively the values Yes, No and Pending, and the cell-link B1001. Thus, when selecting Yes, you get 1 in B1001, when selecting No you get 2 in B1001 and when selecting Pending you get 3 there
So, you may easily refer the cell-link B1001 in your VBA modules
Or use the value displayed in the combo-box the following way
v_combodisplay=range(my_sheet & "!A" & cstr(range(my_sheet & "!B1001).value + 1000)).valu

Or is it that you mean to use a combo-box in a form
Then, that is a different thing

Still, I believe this will help

----- Tibow wrote: ----

I'm having trouble using lists and combo boxes. Basically,
I'm new at using them
I want a combo box/lists to have 3 values I can select,
Yes/No/Pending. I was thinking maybe lists/combos work
like validation, where you can store the value in the
control or on the worksheet, but can't get either way to
work. I've tried tinkering with row source and column
source but no luck

Can anyone help me please....

Thank

  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,272
Default List boxes/combo boxes

Tribe,

Why not use optionbuttons, and a command button. Here is some code for the
commandbuttonj, assuming control toolbox controls that will check which is
set.

Private Sub CommandButton1_Click()
If OptionButton1.Value = True Then
MsgBox "Yes"
ElseIf OptionButton2.Value = True Then
MsgBox "Pending"
ElseIf OptionButton3.Value = True Then
MsgBox "No"
Else
MsgBox "Nothing selected"
End If
End Sub

--

HTH

Bob Phillips
... looking out across Poole Harbour to the Purbecks
(remove nothere from the email address if mailing direct)

"Tibow" wrote in message
...
I'm having trouble using lists and combo boxes. Basically,
I'm new at using them.
I want a combo box/lists to have 3 values I can select,
Yes/No/Pending. I was thinking maybe lists/combos work
like validation, where you can store the value in the
control or on the worksheet, but can't get either way to
work. I've tried tinkering with row source and column
source but no luck.

Can anyone help me please....

Thanks



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 27,285
Default List boxes/combo boxes

for a combobox or listbox from the control toolbox toolbar,
on a worksheet
in design mode (upper left button on the control toolbox toolbar
depressed)
right click on the box and select properties
ListFillRange
Enter Sheet3!B9:B11 as an example
Get out of design mode
on a Userform
in the VBE, click on the box. Make sure the properties window is
visible (F4)
go to the rowsource property and enter
Sheet3!B9:B11

Or you can populate it with code. On a userform
Private Sub Userform_Initialize()
With Combobox1
.AddItem "Yes"
.AddItem "No"
.AddItem "Pending"
End With
End Sub

There is also a dropdown control on the Forms Toolbar. Beto gave you some
information on that. Post back if you need more.

--
Regards,
Tom Ogilvy

"Tibow" wrote in message
...
I'm having trouble using lists and combo boxes. Basically,
I'm new at using them.
I want a combo box/lists to have 3 values I can select,
Yes/No/Pending. I was thinking maybe lists/combos work
like validation, where you can store the value in the
control or on the worksheet, but can't get either way to
work. I've tried tinkering with row source and column
source but no luck.

Can anyone help me please....

Thanks



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
Getting Combo boxes to change options based on other Combo boxes. Ancient Wolf New Users to Excel 1 March 27th 09 06:29 PM
Selecting subsets using combo boxes or list boxes CLamar Excel Discussion (Misc queries) 0 June 1st 06 07:43 PM
combo n list boxes floral_passion Excel Discussion (Misc queries) 1 April 8th 06 10:12 AM
Questions on combo boxes and list boxes. Marc New Users to Excel 1 March 14th 06 09:40 AM
Combo/List Boxes Fordy New Users to Excel 2 March 9th 06 10:07 AM


All times are GMT +1. The time now is 01:57 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"