automatic replacing of a VBE sub in all open workbooks
hi all !
i know how to make automatic replacing of a cell for all open workbooks.. now i neeed to replace a sub with another 1 with a little difference.. is there a way to make it ? tx ! |
automatic replacing of a VBE sub in all open workbooks
You can write another Sub procedure and call it from a third procedure based
on conditions: Sub master() If Range("A1") < "Condition" Then Macro1 Else Macro2 End If End Sub Sub Macro1() MsgBox "Macro1" Range("A1") = "Condition") End Sub Sub Macro2 MsgBox "Macro2" Range("1").ClearContents End Sub "pls123" wrote in message ... hi all ! i know how to make automatic replacing of a cell for all open workbooks.. now i neeed to replace a sub with another 1 with a little difference.. is there a way to make it ? tx ! |
automatic replacing of a VBE sub in all open workbooks
tx for help !
"JLGWhiz" wrote: You can write another Sub procedure and call it from a third procedure based on conditions: Sub master() If Range("A1") < "Condition" Then Macro1 Else Macro2 End If End Sub Sub Macro1() MsgBox "Macro1" Range("A1") = "Condition") End Sub Sub Macro2 MsgBox "Macro2" Range("1").ClearContents End Sub "pls123" wrote in message ... hi all ! i know how to make automatic replacing of a cell for all open workbooks.. now i neeed to replace a sub with another 1 with a little difference.. is there a way to make it ? tx ! . |
All times are GMT +1. The time now is 04:56 AM. |
Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com