Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a Macro from module
I have Public Sub Unlockbuttons() Macro recorded in a module. How do I execute this macro from within code in a userform. I'm using this code: If Sheet6.Range("f49") = 0 And Sheet6.Range("f59").Text = Sheet6.Range("f50").Text Then 'Here is where I need the code to execute the Unlockbuttons macro Would appreciate any guideance Cheers Peter (Working my way through first VBA project) -- peter.thompson ------------------------------------------------------------------------ peter.thompson's Profile: http://www.excelforum.com/member.php...o&userid=29686 View this thread: http://www.excelforum.com/showthread...hreadid=503579 |
#2
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a Macro from module
Hi Peter,
Try: With Sheets("Sheet6") If .Range("F49").Value = 0 _ And .Range("F59").Value = .Range("F50").Value Then Call UnlockButtons End If End With --- Regards, Norman "peter.thompson" <peter.thompson.21yxly_1137819601.3662@excelforu m-nospam.com wrote in message news:peter.thompson.21yxly_1137819601.3662@excelfo rum-nospam.com... I have Public Sub Unlockbuttons() Macro recorded in a module. How do I execute this macro from within code in a userform. I'm using this code: If Sheet6.Range("f49") = 0 And Sheet6.Range("f59").Text = Sheet6.Range("f50").Text Then 'Here is where I need the code to execute the Unlockbuttons macro Would appreciate any guideance Cheers Peter (Working my way through first VBA project) -- peter.thompson ------------------------------------------------------------------------ peter.thompson's Profile: http://www.excelforum.com/member.php...o&userid=29686 View this thread: http://www.excelforum.com/showthread...hreadid=503579 |
#3
Posted to microsoft.public.excel.programming
|
|||
|
|||
Calling a Macro from module
Thanks Norman, much appreciated Cheers Peter -- peter.thompson ------------------------------------------------------------------------ peter.thompson's Profile: http://www.excelforum.com/member.php...o&userid=29686 View this thread: http://www.excelforum.com/showthread...hreadid=503579 |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
calling a module | Excel Discussion (Misc queries) | |||
Calling worksheet module from other module. | Excel Programming | |||
Calling an Excel/VBA User Created Module from WSH | Excel Programming | |||
Calling Worksheet SubProcs From Module | Excel Programming | |||
Calling VBA function that is in another module | Excel Programming |