![]() |
Else:
I just took over an excel spreadsheet from a guy who got
fired. In one of his macros he is using a series of nested if statements and at the end of his if he puts Else: and then ends the if with an EndIf. Is this Else: statement necessary? Does the colon indicate an end of executables under the else? |
Else:
in most cases, else is only necessary if its possible for
there to be an else. if ther is, and the program comes across it, the program will jsut end - no problems hope that helps! ps: was it necessary to tell everyone about the firing of a coworker? haha -----Original Message----- I just took over an excel spreadsheet from a guy who got fired. In one of his macros he is using a series of nested if statements and at the end of his if he puts Else: and then ends the if with an EndIf. Is this Else: statement necessary? Does the colon indicate an end of executables under the else? . |
Else:
The colon after the Else allows statements to be on one
line. If <something here Then <do this Else:End If The Else above is not necessary. If <something here Then <do this Else: <do this End If Keep the Else in the statement above -----Original Message----- I just took over an excel spreadsheet from a guy who got fired. In one of his macros he is using a series of nested if statements and at the end of his if he puts Else: and then ends the if with an EndIf. Is this Else: statement necessary? Does the colon indicate an end of executables under the else? . |
Else:
Thanks! That's what I thought but I justed wanted to make
sure and no one here had seen that syntax before. Thanks again! -----Original Message----- The colon after the Else allows statements to be on one line. If <something here Then <do this Else:End If The Else above is not necessary. If <something here Then <do this Else: <do this End If Keep the Else in the statement above -----Original Message----- I just took over an excel spreadsheet from a guy who got fired. In one of his macros he is using a series of nested if statements and at the end of his if he puts Else: and then ends the if with an EndIf. Is this Else: statement necessary? Does the colon indicate an end of executables under the else? . . |
Else:
Thanks!
Yes, I thought it necessary to rub it in. ;) -----Original Message----- in most cases, else is only necessary if its possible for there to be an else. if ther is, and the program comes across it, the program will jsut end - no problems hope that helps! ps: was it necessary to tell everyone about the firing of a coworker? haha -----Original Message----- I just took over an excel spreadsheet from a guy who got fired. In one of his macros he is using a series of nested if statements and at the end of his if he puts Else: and then ends the if with an EndIf. Is this Else: statement necessary? Does the colon indicate an end of executables under the else? . . |
All times are GMT +1. The time now is 10:19 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com