Within VB, how to pass results of a FormulaArray to a variable.

G

Guest

I am working with a series of matrices. I want to load the first matrix with
constants. I know how to do that. I then want to use some functions like
MMULT and MINVERSE and put the results (sometimes one number, sometimes a
matrix) into an object where I can reference the value in a subsequent matrix
operation. When I merely dimension an array, I can't seem to pass the
results of a matrix function to that array or use the array within a matrix
function.

On a similar issue with arrays, I have a project where I want to delete
mutliple sheets based upon some selection criteria. I could do it one at a
time, but it gets annoying answering the question "Do you want to delete".
Therefore I'd like to delete and array of sheets. When I record the action
of grouping sheets and then deleting them, I notice it uses
"Array(sheet1,sheet2,sheet3)". Is there a way I can load an array with the
sheets I want to delete and then issue one delete statement?
 
G

Guest

With regards to deleting sheets, yes you can delete them in one go and you
can prevent the "Are you Sure" from popping up by disabling alerts (then
enabling after you've deleted the sheets).

Application.DisplayAlerts = False
Sheets(Array("Sheet3", "Sheet4")).Delete
Application.DisplayAlerts = True
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top