Ao apagar um módulo, todas as funcionalidade da planilha dependentes desse módulo ficam automaticamente inativas. Que dica hein!
Segue o código: DelVBComponent ActiveWorkbook, "mdl_MainFunctions"
Sub DelVBComponent (ByVal wb As Workbook, ByVal CompName As String)' deletes the vbcomponent named CompName from wbLet Application.DisplayAlerts = FalseOn Error Resume Next ' ignores any errorswb.VBProject.VBComponents.Remove wb.VBProject.VBComponents (CompName)' delete the componentOn Error GoTo 0Let Application.DisplayAlerts = TrueEnd Sub