VBA Select Case – Using VBA Select Case Statement in Excel. Once you have your list entered, apply a name range: Select the list, including the header (A1:A6). I had a challenging time scouring the various Excel sites for info on how to use the info on a form if the user can make multiple choices; for example, once the user checks the desired boxes in a multi-select checkbox/listbox, how do I get those items and write them to a range?. The problem with your question, is that i investigate, i was working in VBA to make it, with the code ready for making formatting for the item, i could find how, finally in a blog, they say it is imposible, also they say it would be possible with. Select the control in the list and press OK. How to move item in listBox up and down access VBA? only proceed if there is a selected item If lbfNames. ' Select item 4 in ListBox1. you can select only one item at one go in the lisbox. On this page are a few tips on how you can control the format. Set selected item in a ListBox:. This event is triggered when an item of the combo box is selected. accdb) file, and to a Microsoft Access project (. An Event occurs when certain actions are performed by the user or VBA. Access Archon #132. The Selected property is an array with the same number of elements as there are items in a ListBox. Additional Resources. C# ComboBox Control C# controls are located in the Toolbox of the development environment, and you use them to create objects on a form with a simple series of mouse clicks and dragging motions. This list box will enable you to multi-select from multiple items and multiple columns and quickly add them to a dataset. A simple form might contain the date picker control and an Active-X button which uses the final date selected by the user in the Date Picker. Let us explore how to create, clear and make a VBA ListBox let you select multiple. MultiExtended - Multiple items can be selected, and the user can use the SHIFT, CTRL, and arrow keys to make selections. VBA Excel - Type & Choose in a Listbox Creating userforms in Microsoft Excel is great in helping users navigate through their choices and help them achieve their desired outcome. Presses Spacebar when a command button, check box, option button, or toggle button has the focus. This list box will enable you to multi-select from multiple items and multiple columns and quickly add them to a dataset. VBA is the window into Excel's soul - unveiling the Wizard behind the curtain. ServerXMLHTTP60 have any standard VBA events that can be trapped by declaring a variable with the WithEvents keyword. List(i) End If Next i End Sub Additional Resources: Look at Excel VBA Help for the ActiveX ListBox Object - Hammer. It means that when i click an item, other grey out. I have a userform that has a listbox control on it. In order to make use of the user's selection of single or multiple items it is necessary to use a VBA procedure to examine the list, determine what has been selected, and act on it. Here's a VBA tip on how to capture the Double Click event and do something useful with it. SelectedItem. For example when you open a workbook the Workbook_Open event is triggered. MultiSimple - Multiple items can be selected. The Microsoft Excel CASE statement has the functionality of an IF-THEN-ELSE statement. SelectedIndex = 4 'Or do this: ListBox1. to access the value from listbox val=ListBox1. Add a list box to your Excel worksheet from which users can choose a value. Get the selected items in a ListBox. How to unselect radio buttons in MS Access after it has been selected Radio buttons are useful MS Access user interface control element in Access Forms design. Having dates in a ComboBox or ListBox in Excel VBA can be a real teaser, because VBA changes the date format, and that may not be the way you want the dates displayed. Count - 1 If ListBox1. A combobox is very useful when there are many values to choose from and when you only want to show the. A ListBox with unique items. It enables a user to interact, using a Form, in an organized and logical manner, to make data entry or for data retrieval with an Excel worksheet or to run a VBA application. The data displays fine and I am able to select a given row. Get selected item in a ListBox selection event : ListBox « GUI « VB. Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers. This control is similar to the combobox control except that, there is no dropdown option. But again, I'm still struggling on getting the dropdown list to show a Chart Name/Description, and then input the link code. You can find the complete list of event procedures for a control at the top of the Code Window. A user can select an item from the list. On this page are a few tips on how you can control the format. change page in multipage? 0 votes asked Mar 5 in VBA by Slymukabi Beginner ( 5 points). BoundColumn: Dentro de un ListBox pueden desplegarse más de una columna de datos a la vez así como más de una fila. Selected = True Then val= ListBox1. in a subroutine triggered by the Workbook. VBA Excel - Type & Choose in a Listbox Creating userforms in Microsoft Excel is great in helping users navigate through their choices and help them achieve their desired outcome. List box in VBA is a list which is assigned to a variable and the list has various inputs to select upon, from the list box we can select multiple options at once, list box can be made to a userform in excel VBA by selecting the list box option and drawing it on the userform for a list box we have a named range which has certain values provided to select in a list box. ActiveX controls work a bit differently. Double Click on the Control. Private Sub ListBox1_DblClick(ByVal Cancel As MSForms. What I’m looking for is the following: 1. List(i) & vbNewLine End If Next i MsgBox Msg Unload UserForm1 End Sub. You can add a Form Control or an ActiveX Control combo box. In the vast majority of cases, a userform contains a static list of items: these captions, those textboxes, such-and-such commandbuttons, etc. By default, the value is blank but when you initialize or refresh a ComboBox or ListBox, you may want to select the first item in the list. you can select only one item at one go in the lisbox. A combobox is very useful when there are many values to choose from and when you only want to show the. Hi All, I have the below code which deletes all items from a listbox and my excel sheet which is the source for populating that listbox. ScreenUpdating = False 'Declare variables for row and ListBox item index. Net Tutorial Get selected Items in a ListBox: 14. Goto Range(ListBox1. The Excel VBA UserForm allows you to create a new Excel custom Window with select Form or ActiveX controls such a Button, ListBox, CheckBox and other controls. Excel's Data Validation tool offers a quick way to choose an item from a list. Follow these steps: Activate the VBE, and select the VBA module that contains the procedure. Sign up for the course to learn how to get the most from your spreadsheets. accdb) file, and to a Microsoft Access project (. ListBox VBA Excel Example Macros Codes for Adding new Items,Moving all Items, selected Items from ListBox to another ListBox,clearing,Multi selection. Below you will find a complete tutorial on how to create and customize your own Excel VBA UserForm. I have a userform that has a listbox control on it. One way is to "hard code" the list into the UserForm's Initialize event procedure using the. The code works for the first selected value, but by the time it runs the second macro, and goes back to repeat for the second selected value (from the ListBox), the ListBox value seems to have disappeared. Selected(r) = True Next r Else For r = 0 To…. There is no direct way to determine whether the cause of the event was user input or VBA code. However, when the Multi Select property is set to "Simple" or "Extended" the list box has a value of Null regardless of how many or which items are selected. In the ActiveX Controls group, click List Box. Not an expert with ActiveX Controls, but here's something to get you started. We’re a dedicated, cohesive team, so SQLRally is in good hands. This event is triggered when an item of the combo box is selected. Figure 18-4 shows how this looks. The listbox is populated with a few rows of data with the first row being "Select All". The listbox role is used for lists from which a user may select one or more items which are static and, unlike HTML elements, may contain images. It enables a user to interact, using a Form, in an organized and logical manner, to make data entry or for data retrieval with an Excel worksheet or to run a VBA application. MultiExtended - Multiple items can be selected, and the user can use the SHIFT, CTRL, and arrow keys to make selections. For the worksheet version of this example, go to the Excel VBA Move ListBox Items. Your code worked when I assigned it to the Change event and changed the bits that reference ListBox2 to use the name of my List Box. ActiveX controls work a bit differently. My question is, did clicking on the item in the ListBox ever actually select the item, before canceling it? This may be the case, based on the first test I mentioned above. Thanks a lot for this posting, really nice and understandable, but nonetheless I got stuck with a similar problem like Kaion: I’ve got an event-node-type with date-field and want the dates to appear on the webform select list. Excel VBA use Inputbox to select options In my previous post , I demonstrated how to use VBA Inputbox to input a value and create Msgbox to return the value. VBA userforms have 23 different events Windows Forms have 83 different events. I'd like to get the index of the selected item in a ListBox in VBA. Private Sub ListBox1_DblClick(ByVal Cancel As MSForms. These events are built into Excel VBA and are executed automatically by Excel. SelectedItem = ListBox1. AddItem function to add items in the listbox. Figure 14-12 shows a dialog box with two ListBoxes. Selected(4) = True Example. VBA userforms have 23 different events Windows Forms have 83 different events. How to Clear Items from Listbox. Rather than not selecting a value for list box controls or setting a specific default value, you can set it to the first value in the list. Text), True End Sub This code is for: when you double click in cell address which appears in list box it selects the row in which is the record, but when record is on other sheet it does not show. You can use the Selected property to select items in a list box by using Visual Basic. So simply clicking into blank space of the userform wouldn't kick off the exit and the list box remains. On the Insert menu, click. The sample file also contains a more complex solution which lists two properties of the sheets. , user opens screen selects from listbox, then can select from combobox. Anything that you. You should change the CheckOnClick property to True to let the user check and uncheck elements with a single click. Regds Basant s/w engg «. Selecting multiple values from List box using VBA in Microsoft Excel. Excel, Outlook, Access, Powerpoint. CheckedListBox - Allows the user to select multiple items from a list of items. I'd like to get the index of the selected item in a ListBox in VBA. How to Clear Items from Listbox. There is no ToolTipText property associated with any of the controls. Pulling the worksheet range directly into a listbox; Pulling the data into an array first, then placing the array in the listbox; The intention of both of these pieces of code is to be used in a userform. and then I also found this post by MVP Greg Maxey on setting up a Userform list from the excel data populate_userform_listbox_or_combobox. ListCount > 1 Then 'index 0 is top item which can't be. I am using VBA for Access 2002/3. VBA UserForm – How to automatically switch to next Textbox. ListBox: common properties and events : Common properties Value List The value of the list box. You can use this event to get which item in your List or Combo box was selected. Excel VBA UserForm Listbox. The listbox role is used for lists from which a user may select one or more items which are static and, unlike HTML elements, may contain images. You should change the CheckOnClick property to True to let the user check and uncheck elements with a single click. I have a userform that has a listbox control on it. This video show show to Remove Item By Double Clicking a Listbox and Setting Index after Removing Item. vba excel combobox selected item event generated on lbartman. ), they raise events, which VBA can respond to. This article gives two methods to fill a multi column listbox on a userform with data from an Excel worksheet. Introduction to CS VBA #3 - Userforms [email protected] But to allow multiple values, we would also need to use the ActiveX control list box. Lacunsta, I viewed the call stack and it showed that the Mousemove event was being triggered. ListBox VBA Excel Example Macros Codes for Adding new Items,Moving all Items, selected Items from ListBox to another ListBox,clearing,Multi selection. I’m so geeked that we’re hosting the event and I just wanted to take a moment to thank the other members of the team who’ve worked so hard to. The sample file also contains a more complex solution which lists two properties of the sheets. How to move item in listBox up and down access VBA? only proceed if there is a selected item If lbfNames. ListCount ' Loop through the items, checking each one ' to see if it is selected For i = 0 To (cnt - 1) If ListBox1. vba excel combobox selected item event generated on lbartman. I will use the form that I created for How to Add Items from File Dialog to Listbox and add a Clear List button. The ComboBox only displays the selected item. When you (or your VBA) saves a workbook, the Workbook_BeforeSave event is triggered. 0 and higher. and then I also found this post by MVP Greg Maxey on setting up a Userform list from the excel data populate_userform_listbox_or_combobox. I tested using Visual Studio 2012 on a Windows 8 PC. The Excel VBA UserForm allows you to create a new Excel custom Window with select Form or ActiveX controls such a Button, ListBox, CheckBox and other controls. You will be familiar with previous and next buttons if you have used Microsoft Access or any similar userform based database. How to retrieve the selected items in a multiple selection List Box as a comma-delimited string in Microsoft Access Vsebino zagotavlja Microsoft This article applies to either a Microsoft Access database (. Under the Design Menu, click a Command button icon then place it below the Add File button. Most of the time, you won’t have any more code in the procedure. This control inherits from the ListBox control and therefore has the same properties, methods and events. But before doing so. Mouse Click Event in VBA. For the worksheet version of this example, go to the Excel VBA Move ListBox Items. I'd like to get the index of the selected item in a ListBox in VBA. Now you Select SpinUp and SpinDownEvents from the Even Drop down as shown below in image:. (Q) How can I limit the contents of one combo/list box based on what's selected in another combo/list box? (A) An easy way to do this would be to assign a dynamic SQL statment to the RowSource of the secondary combo/list box at runtime. change page in multipage? 0 votes asked Mar 5 in VBA by Slymukabi Beginner ( 5 points). Most of the time, you won’t have any more code in the procedure. Clear End With End Sub Step IV : Right click on ListBox and Select Properties >> Click on "Categorized" and then select "1 - fmMultiSelectMulti" from the drop down in. Use the ItemData Property to obtain the value of the Bound Column. Show a listbox, when a cell with an Excel drop down list is selected. Here is a sample VBA code to help you ‘Event handler to add …. This Excel VBA example moves items from one listbox to another, on an Excel UserForm -- either all the items, or just the selected items. Pulling the worksheet range directly into a listbox; Pulling the data into an array first, then placing the array in the listbox; The intention of both of these pieces of code is to be used in a userform. Excel advanced filtering with userform. But again, I'm still struggling on getting the dropdown list to show a Chart Name/Description, and then input the link code. I am using excel 2011 on a Mac. Note: Read the info good, if you want a solution for all excel versions a custom calendar in a add-in is a better option, check out the links on top of this page for more information. The first item in a ListBox has a ListIndex of 0, not 1 (as you may expect). Displaying a UserForm. Select multiple items from the list, and all selected items are entered in the active cell. You can show the list of items in the listbox and user can select any item and do different operations. Below you will find a complete tutorial on how to create and customize your own Excel VBA UserForm. Re: Double click Listbox to edit item Not too sure I understand correctly. So let's put the sheet names into a userform's listbox. How do I select a given item within a listbox using VBA? I have a listbox that records ranges from a Refedit control. imaginons que je selectionne la ligne 1, 10 et 25, je souhaiterais afficher dans une cellule excel les 3 valeurs selectionnées en les séparants par le symbole / Vba listbox selected;. Setting this property to True or False will select or deselect an item, respectively. There is no ToolTipText property associated with any of the controls. The other major difference between them is that the ListBox allows multiple selections and the ComboBox doesn’t. Digamos que tenemos un ListBox con tres columnas y 10 filas de datos. Selecting Multiple Options in Dependent Drop Down List Box using VBA no comments In our earlier blog we have already discussed how to create a dependent drop down list box in Excel and as well as in VBA when we are using the list box in VBA. This control is used to display list of items to a list. Use VBA to modify an SQL statement, such as for defining what appears in a list box when the Form_Current event occurs. The first item which is added to ListBox will be indexed as 0, Second One will be Indexed as 1 and so on. Selected property of the list box could be used:. Please find more details about ListBox_Control in the following chapter. ListBox is one of the UserForm control. Trouble is, the AfterUpdate event does not occur if the Listbox is set to allow multiple selection Steps to replicate behaviour: Add a UserForm (UserForm1), & add a single Listbox to the form (Listbox1). You can add a Form Control or an ActiveX Control combo box. These events are built into Excel VBA and are executed automatically by Excel. If you want an "All" option: it either needs to be part of the "ListFillRange" you selected in the properties dialog --or-- you need to set ListFillRange to nothing and instead populate the listbox through VBA. Fill a ListBox control with values from closed workbook using VBA in Microsoft Excel In this article, we will fetch data from closed workbook to List box in userform using VBA. To create a list box in Excel VBA, execute the following steps. One way is to "hard code" the list into the UserForm's Initialize event procedure using the. Listbox VBA Code – Dynamic Userform Listbox. I created a code at the listbox's Click event. Regds Basant s/w engg «. You should change the CheckOnClick property to True to let the user check and uncheck elements with a single click. Show a listbox, when a cell with an Excel drop down list is selected. Free E Books: www. Private Sub ListBox1_DblClick(ByVal Cancel As MSForms. Make data entry easier by letting users choose a value from a combo box. How to retrieve the selected items in a multiple selection List Box as a comma-delimited string in Microsoft Access Vsebino zagotavlja Microsoft This article applies to either a Microsoft Access database (. The CASE statement is a built-in function in Excel that is categorized as a Logical Function. Note: you can change the name of a control by. " End If End Sub VBA ListBox Default Values in Excel. To select an item in a ListBox, we can use the SetSelect method that takes an item index and a true or false value where the true value represents the item to be selected. I want to populate a textbox based on the row selected from the listbox. Illustrate using an ActiveX ListBox in a Worksheet & Macro associated with its Click event, in Excel VBA, to categorize BMI using weight & height. change page in multipage? 0 votes asked Mar 5 in VBA by Slymukabi Beginner ( 5 points). Select Multiple Items from Popup Listbox. Here is the code so far. You have to click on the ComboBox to see the other available items. ListCount - 1 If ListBox1. Access: Select All Items in a List Box Posted by Stacy Posted on Thursday, July 28, 2011 6 comments Last week I was working on a Microsoft Access database I've been building and was making some changes to a form that allows users to select one or many items from a list box in order to set criteria for a report. Addins for excel and powerpoint. It can be used as a VBA function (VBA) in Excel. Trouble is, the AfterUpdate event does not occur if the Listbox is set to allow multiple selection Steps to replicate behaviour: Add a UserForm (UserForm1), & add a single Listbox to the form (Listbox1). But again, I'm still struggling on getting the dropdown list to show a Chart Name/Description, and then input the link code. Excel UserForms UserForm is a customized user interface, developed in VBA. pl Action 2 (selection): when the user selects an item from the left ListBox andclick the ">>" CommandButton, two actions occur: 1. The ComboBox only displays the selected item. Figure 18-4: Determining which item in a ListBox is selected. I have set up a user form with a ListBox of 10 numbers. and then I also found this post by MVP Greg Maxey on setting up a Userform list from the excel data populate_userform_listbox_or_combobox. Get selected item in a ListBox selection event : ListBox « GUI « VB. That part works without issues. Changing colour of selected items in listbox. How to list/populate sheet names to a Listbox on a Userform. Select the control in the list and press OK. Okay, it's actually some simple code that allows you to Automate almost anything in Excel. You can use the Selected property to select items in a list box by using Visual Basic. You have to click on the ComboBox to see the other available items. My problem is that the click event is not recognizing changes made to the listbox. double click event. In this example I’m going to show you how to create a previous and a next button in a userform in the Microsoft Excel using VBA. Private Sub ListBox1_DblClick(ByVal Cancel As MSForms. To determine the items that are selected, you can use the Selected property of the list box. In versions d'Excel lower than 2007: the button is on the "Controls Toolbox" toolbar. The Complete Guide to Excel VBA Form Control ListBoxes (wellsr. Excel Vba Merge And Center - 2; Excel Vba Merge And Center; Right-Click Context Menu On Userform. Let's understand with the simple exercise:- We have taken data in which we have email id detail for every employee. AJP Excel Information. Limit number of selections in a multiselect ListBox in Excel. The user selects "Value 4" from the drop down list: Result: Note: Drop down lists are zero based, therefore the first item has the index "0" and the last item has the index "n-1" where "n" is the number of items in the drop down list. ListCount = 0 Then Exit Sub 'GoTo doubled clicked address Application. How to use the VBA Editor. If "Unique" is checked on the form, we test each value before adding it to the ListBox's array. So simply clicking into blank space of the userform wouldn't kick off the exit and the list box remains. The following example uses the Selected property to move selected items in the lstSource list box to the lstDestination list box. It's often useful to create a new list of the selected items and display the new list in another ListBox. ListBox VBA Excel Example Macros Codes for Adding new Items,Moving all Items, selected Items from ListBox to another ListBox,clearing,Multi selection. The data displays fine and I am able to select a given row. You can use the Selected property to select items in a list box by using Visual Basic. The list box shows all hobbies, with the selected items in the list being the hobbies held by the current family member. and then I also found this post by MVP Greg Maxey on setting up a Userform list from the excel data populate_userform_listbox_or_combobox. In this ArticleCreate a ListboxPopulate a Listbox in VBA codePopulate a Listbox from a Cells RangeGet a Selected Item of a Listbox in VBAClear a ListboxUse a Listbox in a Userform In VBA, you can create a Listbox where a user can choose one of the listed options. Selected(r) = True Next r Else For r = 0 To…. Excel 97-2010, 2010 only the 32 bit version. Private Sub ListChoices() Dim i As Integer Dim cnt As Integer ' Get the number of items in the list cnt = ListBox1. ReturnBoolean) 'Check for range addresses If ListBox1. but my main question to the group is this possible. ' (Alternatively set ListBox1. When you are working with other applications (such as Microsoft Word and Internet Explorer), the libraries associated with those applications need to be included in. A ListBox with unique items. However, if the user has selected an invalid range, I want to let them see a meaningful message, set the focus to the listbox and then select/highlight the invalid range. It can be used as a VBA function (VBA) in Excel. The first item in a ListBox has a ListIndex of 0, not 1 (as you may expect). " End If End Sub VBA ListBox Default Values in Excel. For example when you open a workbook the Workbook_Open event is triggered. You can use the Selected property to select items in a list box by using Visual Basic. An Event Procedure is a VBA Sub procedure that is executed automatically by Excel when the event is raised. But, I want to limit the number of selections to 3. VBA is the window into Excel's soul - unveiling the Wizard behind the curtain. Add Columns in VB. Crystal Long teaches and develops with Microsoft Access, Excel, and Office and specializes in remote training. In order to get Properties window you can Press F4 or by right-clicking on a control to get the "Properties" menu item. Let us explore how to create, clear and make a VBA ListBox let you select multiple. The WPF ListBox control is one of the simplest and most basic list controls available in the Windows Presentation Foundation of Microsoft NET Framework 3. iqbalkalmati. imaginons que je selectionne la ligne 1, 10 et 25, je souhaiterais afficher dans une cellule excel les 3 valeurs selectionnées en les séparants par le symbole / Vba listbox selected;. The following code snippet sets a ListBox to allow multiple selection and selects the second and third items in the list:. The listbox role is used for lists from which a user may select one or more items which are static and, unlike HTML elements, may contain images. Selecting Outlook Contacts for Word Letters from a Multi-Select Listbox. Follow these steps: Activate the VBE, and select the VBA module that contains the procedure. Re: Double click Listbox to edit item Not too sure I understand correctly. [Resolved] Vba code to edit listbox selected item If this is your first visit, be sure to check out the FAQ by clicking the link above. There is no direct way to determine whether the cause of the event was user input or VBA code. Because I never find it when I need it - A way to fill a multi-column listbox (or combobox) with VBA Things to keep in mind: You must set the ColumnCount property of the listbox to 2 (or more, depending on how many columns you want You should also set ColumnWidths to define the widths of each…. The solution? Adding a multi-selection list box to the worksheet. Under the Design Menu, click a Command button icon then place it below the Add File button. In this ArticleCreate a ListboxPopulate a Listbox in VBA codePopulate a Listbox from a Cells RangeGet a Selected Item of a Listbox in VBAClear a ListboxUse a Listbox in a Userform In VBA, you can create a Listbox where a user can choose one of the listed options. Ago ,the products are filled with unique items into combobox and sorted alfabetically. Selected(i) Then Msg = Msg & ListBox1. When an item in the listbox is selected data populates the two text boxes on the userform with information from the "Lookup" sheet. Value if u have set selection mode property to multiple then access it through for loop as For i = 0 To ListBox1. Using CheckBox to select all items in a ListBox by Lilyfield » Fri Jun 29, 2012 2:37 pm I would like assistance in writing code to have the user check a box (CheckBox5) on a UserForm (UserForm3), that will trigger the selection of all items in a ListBox (ListBox1). What I'm looking for is the following: 1. One way is to "hard code" the list into the UserForm's Initialize event procedure using the. Hi All, I have a textbox that searches the listbox below it and selects the text that I types in the textbox. That part works without issues. File crashes Excel!! Save my workbook! The best tool for salvaging problematic workbooks. This control displays all the items and if the number of items exceed the size of the control,. Selecting Multiple Options in Dependent Drop Down List Box using VBA no comments In our earlier blog we have already discussed how to create a dependent drop down list box in Excel and as well as in VBA when we are using the list box in VBA. Fill a ListBox control with values from closed workbook using VBA in Microsoft Excel In this article, we will fetch data from closed workbook to List box in userform using VBA. The difference between a combo box and a list box is that the combo box is a drop-down list and the user can submit a single value from the drop-down list. A Double Click event is simply an event that fires when you double click on a cell This example will demonstrate how to provide a simple interface to cycle through a series of values that enables a user of your Excel system to avoid entering things. In this Excel VBA & macros tutorial, you will learn how to create a ListBox that contains the names of the worksheets. Windows 10/Office 365 – Excel 2016 (32-bit) Related link(s): VBA function to get index number for selected item from list type data validation. List(i) End If Next i End Sub Additional Resources: Look at Excel VBA Help for the ActiveX ListBox Object - Hammer. But again, I'm still struggling on getting the dropdown list to show a Chart Name/Description, and then input the link code. But to allow multiple values, we would also need to use the ActiveX control list box. This can occur when the form loads, or if the RowSource values of the ListBox or ComboBox change based on another selection (see our tip on Cascading ComboBoxes/ListBoxes). A user can select an item from the list. To make it a little bit more flexible we have also made the listbox dynamic. One way to execute this procedure is by doing so directly from the VBA module in which you defined it. The MultiSelect property in Excel VBA allows a user to select multiple items in a list box.