Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi,
I am using centralized error handling in my VB program whic manipulates excel sheets. My question is this: I have a function which I call whenever a run time error is detected I open a file in my main code. The main code calls other subroutines. When a run time error is detected, the error handling function i called. The erro handling function displays an appropraite message and has th "End" statement. I expect the end statement to close all files that were opened in th program. But it turns out that it only closes files opened in th sub/function where the error occured. Can anyone please tell me how I make sure all files opened durin program execution are closed. Thanks! BrutalMeta -- Message posted from http://www.ExcelForum.com |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Keep track of them and close the ones you want to close????
"brutalmetal <" wrote: Hi, I am using centralized error handling in my VB program which manipulates excel sheets. My question is this: I have a function which I call whenever a run time error is detected. I open a file in my main code. The main code calls other subroutines. When a run time error is detected, the error handling function is called. The erro handling function displays an appropraite message and has the "End" statement. I expect the end statement to close all files that were opened in the program. But it turns out that it only closes files opened in the sub/function where the error occured. Can anyone please tell me how I make sure all files opened during program execution are closed. Thanks! BrutalMetal --- Message posted from http://www.ExcelForum.com/ -- Dave Peterson |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Keep track of them and close the ones you want to close????
"brutalmetal <" wrote: Hi, I am using centralized error handling in my VB program which manipulates excel sheets. My question is this: I have a function which I call whenever a run time error is detected. I open a file in my main code. The main code calls other subroutines. When a run time error is detected, the error handling function is called. The erro handling function displays an appropraite message and has the "End" statement. I expect the end statement to close all files that were opened in the program. But it turns out that it only closes files opened in the sub/function where the error occured. Can anyone please tell me how I make sure all files opened during program execution are closed. Thanks! BrutalMetal --- Message posted from http://www.ExcelForum.com/ -- Dave Peterson |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
handling calculated excel cell error messages | Excel Discussion (Misc queries) | |||
Error handling problem | Excel Discussion (Misc queries) | |||
Handling #NUM! error | Excel Worksheet Functions | |||
Excel Error Handling | Excel Programming | |||
Error Handling | Excel Programming |