ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   How do I create a multiple selection list box in Excel with VBA? (https://www.excelbanter.com/excel-programming/420138-how-do-i-create-multiple-selection-list-box-excel-vba.html)

mateo303

How do I create a multiple selection list box in Excel with VBA?
 
I followed the directions on 2007 help in Excel, but then it said, that I
couldn't link the cells or do anything further without VBA code. Please let
me know how to make this multiple selection list box (Active X) work.

Rick Rothstein

How do I create a multiple selection list box in Excel with VBA?
 
The reason you can't link to a cell is because it is a multiple selection
ListBox. The problem is the user might select more than one item in the
ListBox... which of those items would you expect Excel to put in a linked
cell (assuming it could do that)? The first item in the list? The first item
the user clicked? All of them concatenated together? Whatever it might have
attempted to do, how would it know it was time to do it (that is, how would
it know the user was done selecting items)? There is no right answer here
(as far as Excel is concerned), so it leaves it up to you to use the VBA
interface to craft your (re)action according to your own needs. As to how to
make it work... that depends on what it is you want it to do. Can you
describe what your ultimate goal is?

--
Rick (MVP - Excel)


"mateo303" wrote in message
...
I followed the directions on 2007 help in Excel, but then it said, that I
couldn't link the cells or do anything further without VBA code. Please
let
me know how to make this multiple selection list box (Active X) work.




All times are GMT +1. The time now is 05:09 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com