Home

Cambiar codigo desde otro codigo

%3CLINGO-SUB%20id%3D%22lingo-sub-700762%22%20slang%3D%22es-ES%22%3EChange%20code%20from%20another%20code%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-700762%22%20slang%3D%22es-ES%22%3E%3CP%3EHow%20can%20I%20change%20the%20code%20in%20a%20macro%20from%20another%20workbook%20with%20another%20macro.%3C%2FP%3E%3CP%3EExample.%20I%20have%20this%20code%20and%20I%20want%20to%20change%20the%20date%2C%20but%20using%20code%20not%20a%20cell.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EPrivate%20Sub%20CommandButton1_Click()%3C%2FP%3E%3CP%3E'Disable%20program%20based%20on%20date.%3C%2FP%3E%3CP%3EIf%20Date%20%26gt%3BTM%20%2206%2F19%2F2019%22%20Then%3CBR%20%2F%3EMsgBox%20(%22You%20must%20enable%20this%20program%2C...%20calls%20the%20phone..%20xxxxx%22)%3C%2FP%3E%3CP%3EUnload%20UserForm1%3CBR%20%2F%3E%3CBR%20%2F%3EExit%3CBR%20%2F%3ESub%20End%20If%20'----------------------------------%3C%2FP%3E%3CP%3E'updates%20data%20and%3CBR%20%2F%3E%3CBR%20%2F%3Ereturns%20current%20Update%20End%20Sub%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-700762%22%20slang%3D%22es-ES%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EMacros%20and%20VBA%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Highlighted
lcruzm
Occasional Visitor

Como puedo cambiar el código en una macro desde otro libro con otra macro.

ejemplo. tengo este cóodigo y quiero cambiar la fecha, pero usando código no una celda.

 

Private Sub CommandButton1_Click()

'Inhabilita programa según la fecha..

If Date >= "06/19/2019" Then
MsgBox ("debes habilitar este programa,...llama al fono ..xxxxx")

Unload UserForm1
Exit Sub
End If
'----------------------------------

'actualiza datos y devuelve actual
Actualizar
End Sub

Related Conversations
Tabs and Dark Mode
cjc2112 in Discussions on
22 Replies
flashing a white screen while open new tab
cntvertex in Discussions on
13 Replies
Stable version of Edge insider browser
HotCakeX in Discussions on
35 Replies
How to Prevent Teams from Auto-Launch
chenrylee in Microsoft Teams on
28 Replies
PacketMon Components are not loading in WAC 1909
HotCakeX in Windows Admin Center on
2 Replies