Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.worksheet.functions
|
|||
|
|||
Excel VBA Formula Help
Hi Experts,
With Range("d10,d11,k10,n10,p10,t11,e12,v10") If .NumberFormat = "0" Or .NumberFormat = "General" Then Exit Sub .NumberFormat = "0.0" Else .NumberFormat = .NumberFormat & "0" .NumberFormat = Replace(.NumberFormat, "0000", "000 0") End If End With This is part of a button driven macro. The problem is the exit sub part is causing the rest of the macro to not be run (not shown) I have tried to place another macro call after "Then" but I cant get it to work. It just moans about the ".NumberFormat = "0.0"" part. I just need it to protect the worksheet if it is going to exit sub because at the end of this macros code I protect the sheet. When it exits, It doesnt ever get to run the code part that protects the sheet at the end. TIA, Aaron. |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
When I enter a formula, Excel shows the formula not the results | Excel Worksheet Functions | |||
Excel Formula Guidance. Formula need to determine if cell is popul | Excel Programming | |||
Excel 2002 Formula: Urgent Conditional Formula Required Right Away - if possible | Excel Discussion (Misc queries) | |||
Build excel formula using field values as text in the formula | Excel Worksheet Functions | |||
Excel 2002 formula displayed not value formula option not checked | Excel Worksheet Functions |