Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Hi
IMHO good programming practice should ensure this for each procedure and not on a higher level -- Regards Frank Kabel Frankfurt, Germany "Imbecill" schrieb im Newsbeitrag ... Thank a lot to your respons - yes, error handling and to carefully write the code to take the original values after each sub... But if I miss something there would be nice to have something to unable an OnKey value etc. to continue outside my xls file. Is there nothing I can put in a Workbook_deactivate event or something? /Regards "Frank Kabel" skrev i meddelandet ... Hi try something like sub foo() on error goto errhandler 'your code errhandler: application.enableevents=true end sub -- Regards Frank Kabel Frankfurt, Germany "Imbecill" schrieb im Newsbeitrag ... Hi all, This is about if users get an error in the middle of my code or just leave a sheet for a while to go to a completly other xls-file of they own. Is here a nice way of restore the usual behavour of excel ?? Example: I use "Application.EnableEvent = False" in several Subs of code, but use to have a "Application.EnableEvent = True" in the end of the Sub. The same with a OnKey-code to stop Paste functions. In one Sub I update the sheet/cell formats through copy from a template sheet and SpecialPaste Formats only. Now I discovered in an totally new xls-file, that THAT Sheet took the template formats ... [ Actually, the last behavour shouldn't be able to happen...i have a worksheet_change event to trigg the formatUpdate and the new sheet ( I coudn't say it's a xls file, it wasn't saved as one yet, if this matters...) took the template format when I pasted into a cell !!!! ] Therefore - can I ensure to keep the code into the specific file I've created or it's children... /Regards |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
How do I prevent Excel 2007 from leaving ".tmp" files in my folder | Excel Discussion (Misc queries) | |||
formula error- ("Nesting more than 7 functions"- Feb4) | Excel Worksheet Functions | |||
Excel "Move or Copy" and "Delete" sheet functions | Excel Worksheet Functions | |||
HELP on "left","right","find","len","substitute" functions | Excel Discussion (Misc queries) | |||
can we convert "2 days 16 hrs" to " 64hrs" using excel functions | Excel Worksheet Functions |