ExcelTip.com
ExcelTip.com
Account Icon Account Icon Account Icon
Google Exceltip.com
JOIN OUR NEWSLETTER
  and receive for joining:
Free eBook Learn More!
Free Excel ADD-IN
Free Weekly Excel Tip
4 e-books in cd-rom
F1 Formulas & Functions
F1 Formulas & Functions
F1 EXCEL
F1 eBook (Spanish)
F1 EXCEL
Financial Statements.xls
 

» Add Combo Box to a Sheet in Microsoft Excel
CATEGORY: Excel Tools

What are the Advantages of working with Combo Box?

Choosing an item from a list in the Combo Box returns a number. The number then replaces the use of the Match formula to calculate the column number in the Vlookup formula (read tip) and replaces the use of the Match formula (read tip) to calculate the column number in the Index formula.

Working with the Combo Box

A list of the cell ranges in the sheet is attached to the Combo Box. After an item is selected from the list, the Combo Box enters into the linked cell the ordinal number of the item that is selected on the list.



Example:

The screen shot displays a profit and loss statement as compared to the previous year. Changing the month in the Combo Box will automatically change the display of data according to the selected month.


Step 1: Define names

1.Enter the months list - January-December into the cells A1 to A12 in the new worksheet.

2.Select cells A!:A12, press Ctrl+F3, enter the text MonthsList into the Names In workbook box, and click OK.

3.Select Cell B1, press Ctrl+F3, enter the text MonthNumber into the Names in Workbook box, and click OK.


Step 2: Add a Combo Box to a worksheet

1. Select one of the toolbars, right-click, and select the Forms toolbar.

2. Copy the Combo Box by clicking the Combo Box icon, and then release the mouse. Create a rectangle with the mouse in the worksheet, and then release the mouse.


Step 3: Format the Combo Box


1.Select the Combo Box; right-click; and from the shortcut menu that appears, select Format Control. Then select the Control tab

2.In the Input range box, type the name MonthsList (You cannot press F3 to paste a name with   an object).

3.In the Cell link box, type the name MonthNumber.

4.Click to select the 3-D shading box (more aesthetic).

5.Click OK.

Exit the formatting mode of Combo Box, and select a cell in the sheet. Open the list of items in the Combo Box, and select a month. Note that the new month number is shown in cell B1.


Advantages of working with names in a Combo Box

Attaching a list with Define Names causes your list references to be updated automatically in the Combo Box. Sorting the list in the sheet will automatically sort the list in Combo Box as well.

Deleting a Combo Box

Select the object; right-click; and from the shortcut menu that appears, select Cut.

Adjusting the size of the Combo Box to the cells

Select the Combo Box and right-click; the Combo Box is now in editing mode. Adjust the width or height of the Combo Box by dragging one of the corner boxes; adjust the placement of the Combo Box on the worksheet by clicking anywhere inside the box and dragging it.


Automatic adjustment of the Combo Box 

Hold down the Alt key while you click the mouse to adjust the size of the Combo Box.



Screenshot // Add Combo Box to a Sheet in Microsoft Excel

Add Combo Box to a Sheet in Microsoft ExcelAdd Combo Box to a Sheet in Microsoft Excel
Rate this tip
12 34 5
  RATING: 3.41
  VIEWS: 221814

READER COMMENTS (view all comments)



Jerry wrote on December 31, 1969 19:00 EST
now how to get the value for the seletcted item from this combo box in vba code?
Advantages of Combo than Filter Option
Sandeep Bhatia wrote on December 31, 1969 19:00 EST
Pls. tell me advantages of combo option than filter.
Advantages of Combo than Filter Option
Sandeep Bhatia wrote on December 31, 1969 19:00 EST
Pls. tell me advantages of combo option than filter.
??
itsme6526 wrote on December 31, 1969 19:00 EST
I did as you said here, but I get a numerical value in the cell link box instead of the selected value from the combo box. Any suggestions?
Excel 2003
Swaminathan wrote on December 31, 1969 19:00 EST
I tried with Ms-Office 2003. I am unable to reproduce the above steps since Format control does not have Control tab.
Excel 2003 - Control Tab Missing
Wooksta wrote on December 31, 1969 19:00 EST
Swaminathan: i had the same issue as you (the control tab was missing when I went to format control on the combobox)... The soultion is to use the control box from the "forms toolbox" toolbar and not the "control toolbox" toolbar.

Ash P wrote on December 31, 1969 19:00 EST
I have managed to get the combo box working ok, but instead of the linkcell displaying a number - i want excel to bring up a corrisponding sheet with information on it..much like the way the example brings up different dates of accounts...any ideas? thanks

ronak wrote on December 31, 1969 19:00 EST
hi i want to hide rows and columns using combo box.
i have list of assemblies in a excel file. So when I select any title of the assembly from combo bos, it should hide all the rows above that assembly title.
Same way in a different combo box is select specific vehicle name, then it should hide all the columns before that column with the vehicle name.
its very important for my company, try if if u can help me out with it.
All the best.
excel listbox control tab missing
jonathan wrote on December 31, 1969 19:00 EST
my problem is that excel listbox control tab missing. i needed help on answering this question.
THANK YOU, wooksta.

wooksta said:
Swaminathan: i had the same issue as you (the control tab was missing when I went to format control on the combobox)... The soultion is to use the control box from the "forms toolbox" toolbar and not the "control toolbox" toolbar.

Max showed values = 1050!
Marcel wrote on December 31, 1969 19:00 EST
Is it possible to extend this range?



REGISTERED USERS - Click here to post comments


GUESTS (Click here to register)
Name
Comment Title
Comments

The Financial Numbers Game: Detecting Creative Accounting Practices

Microsoft Windows XP Inside Out

Financial Shenanigans : How to Detect Accounting Gimmicks & Fraud in Financial Reports

Accounting for Dummies

The Accounting Game : Basic Accounting Fresh from the Lemonade Stand

Mortgages For Dummies®

RELATED MICROSOFT EXCEL TIPS


Convert PDF Files to Excel






Excel VBA books
Accounting books
Business Plans
MS Office books
Taxes books

VIEW ALL BOOKS


  Advertise With Us                               

Tips

Add-In in VBA | Applications - Word, Outlook in VBA | Array Formulas | Cells, Ranges, Rows, and Columns in VBA | Counting | Custom Functions | Custom Functions in VBA | Database Formulas | Database in VBA | Date & Time Formulas | Date & Time in VBA | Events in VBA | Excel 2003 | Excel Chart | Excel Consolidating | Excel Counting | Excel Custom Functions using VBA | Excel Customizing | Excel Data | Excel Dates | Excel Editing | Excel Files | Excel Filter | Excel Format | Excel Formula | Excel General | Excel Grouping and Outlining | Excel Importing Text Files | Excel Information | Excel Keyboard Shortcuts | Excel Loan Formulas | Excel Macros - VBA | Excel Pivot Tables | Excel Printing | Excel Range Name | Excel Security - Protection | Excel Sorting | Excel Style | Excel Subtotals | Excel Summing | Excel Text | Excel Time | Excel Tools | Excel Worksheet, Workbook | Files, Workbook, and Worksheets in VBA | Financial Formulas | Formating in VBA | General Topics in VBA | Import and Export in VBA | Information Formulas | Keyboard & Other Shortcuts in VBA | Keyboard Formula Shortcuts | Links between Worksheet and Workbooks | Links in VBA | Logical Formulas | Lookup Formulas | Mail - Send and Receive in VBA | Menus, Toolbars, Status bar in VBA | Modules, Class Modules in VBA | Other Q&A Formulas | Printing in VBA | Protecting in VBA | Summing | Text Formulas | User Forms, Input boxes in VBA | Using Loops | Working with Formulas |

Tips by Version

Microsoft Excel 97 | Microsoft Excel 2000 | Microsoft Excel 2002 | All Microsoft Excel Versions | New in Excel 2002 | New in Excel 2003 - Office 11

Website

Home | Tip of Hour | Recommended Tips | Most Viewed Tips | Tips by Version | Submit a Tip | My Tips
Microsoft Excel Tutorials | Excel Links | Write for Us | About Us | Search Results | Tip Archives | Excel Forum | Excel Forum Archives

Excel Book

Excel 97 Book | Excel 2000 Book | Excel 2002 Book | Excel XP Book | Book Store

Terms and Conditions of use
The applications/code on this site are distributed as is and without warranties or liability. In no event shall the owner of the copyrights, or the authors of the applications/code be liable for any loss of profit, any problems or any damage resulting from the use or evaluation of the applications/code.

Copyright © 2003 ExcelTip.com
Microsoft, Microsoft Excel is a U.S. registered trademark of Microsoft Corporation
Site Developed By: Varien