I have an error that occassionally occurs when running a macro over and
over. It is "Out of stack space". It seems to go away for a little
while when I close the application and start over.
How can I prevent this? What causes it?
TIA
I have an error that occassionally occurs when running a macro over and
over. It is "Out of stack space". It seems to go away for a little
while when I close the application and start over.
How can I prevent this? What causes it?
TIA
You didn't post your code but you may be calling code that recalls your code
that calls that code that recalls your code, etc. Excel get "fed up"
--
Don Guillett
SalesAid Software
donaldb@281.com
"papa jonah" <adullam04-excelgoogle@yahoo.com> wrote in message
news:1113343042.400717.184080@g14g2000cwa.googlegroups.com...
> I have an error that occassionally occurs when running a macro over and
> over. It is "Out of stack space". It seems to go away for a little
> while when I close the application and start over.
>
> How can I prevent this? What causes it?
>
> TIA
>
My guess is you are right. I am recalling stuff from other macros.
However, my intent is to start over everytime. Is there a way to dump
the info at the end of a run, so that the register, stack, or whatever
is clear the next time?
Perhaps you should post your code for all to see.
--
Don Guillett
SalesAid Software
donaldb@281.com
"papa jonah" <adullam04-excelgoogle@yahoo.com> wrote in message
news:1113344510.753029.238880@o13g2000cwo.googlegroups.com...
> My guess is you are right. I am recalling stuff from other macros.
> However, my intent is to start over everytime. Is there a way to dump
> the info at the end of a run, so that the register, stack, or whatever
> is clear the next time?
>
Once the macro is ended, the stack should be like new again.
--
Regards,
Tom Ogilvy
"papa jonah" <adullam04-excelgoogle@yahoo.com> wrote in message
news:1113344510.753029.238880@o13g2000cwo.googlegroups.com...
> My guess is you are right. I am recalling stuff from other macros.
> However, my intent is to start over everytime. Is there a way to dump
> the info at the end of a run, so that the register, stack, or whatever
> is clear the next time?
>
"Tom Ogilvy" <twogilvy@msn.com> wrote in message
news:OjL4$hDQFHA.244@TK2MSFTNGP12.phx.gbl...
>
> Once the macro is ended, the stack should be like new again.
>
> --
> Regards,
> Tom Ogilvy
>
> "papa jonah" <adullam04-excelgoogle@yahoo.com> wrote in message
> news:1113344510.753029.238880@o13g2000cwo.googlegroups.com...
>> My guess is you are right. I am recalling stuff from other macros.
>> However, my intent is to start over everytime. Is there a way to
>> dump the info at the end of a run, so that the register, stack, or
>> whatever is clear the next time?
>
Hi Tom,
Would that mean that control has to entirely transfer back to the
normal user interface from VBA?
I am thinking about the situation where an 'application' has been
built in VBA, whereby a user opens the workbook and is immediately put
into a userform menu system, where they perform various tasks, run
reports etc, and only exit from the workbook via a userform button.
Hence at no time in their use of the workbook, did they ever get to
access the workbook outside of the userform menus.
I have had an example where a user experienced stack overflow after
doing many changes to a workbook in that scenario and the only way to
resolve it seemed to be to force them out of VBA / userform control,
close and reopen the workbook.
Hope that makes sense!
Thanks,
Alan.
There are currently 1 users browsing this thread. (0 members and 1 guests)
Bookmarks