Hi everybody,

I will try to be clear in my problem:

I am creating an Excel form, with expandable lists and other macros. A condition in the macros is to hide some rows if a box is checked.
I have created expandables lists without macro, and I would like them to hide with the rows. After having checked on the net, this looks impossible, as the format option "move and change size with cells" is only available with macro.

So, I would like to replace my current expandable list by a macro with the same function. However I don't know what the code should be.

Currently, my expandable list selects cells from A1 to A10, and if A3 is selected, then the cell B1=3. How can I replace this with a VBA code ?

I am sure the code is very simple, but I am new in VBA...

Thank you !