If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below. If you don't like Google AdSense in the posts, register or log in above.

Re-Dimension Array

Is it possible to define an array with 2 dimensions. Then later redefine with 3 dimensions?

For example:

Dim test(5,10)
Redim test(5,10,15)

Clearly this results in an error, but you can get the idea of what I want to be doing.

To take this a step further, what I want to be able to do is to take some input from the user, they click a button, and based on the number of dimensions they feed in, I want to create that number of dimensions. My simple solution is to limit the number of creations to let's say 5 dimensions and just have a 5-piece SELECT-CASE chunk of code. However I always like to make things that don't have limits like that. Any thoughts?

Events For UserForm Controls At Run-Time

Hi,

Using VBA in Excel 2003.

I've created a userform with a set of dynamic controls (i.e. the combo boxes are created at run time).
I've created a class module to handle events on the combo boxes & this works fine with the _Change event but doesn't work with the _AfterUpdate event.
In examples on the web, the only events that seem to be given are _Change and _Click.

My question is: can I get the _AfterUpdate event to work with these dynamic controls?

I'm happy to post my code if you need it, but as I said it works fine with _Change event, just not _AfterUpdate