Error al configurar recordatorio en evento open workbook
publicado
Hola Amigos de Ayuda Excel, estoy elaborando un macro q me permita recordar una tarea a realizar en una feha determinada, pero este recordatorio se realiza una vez cada mes, yo lo estuve configurando y no se porq no me funciona, anexo dicho codigo para q por favor me ayuden a corregirlo...
de antemano muchas Gracias por su Ayuda.
Option Explicit
Private Sub Workbook_Open()
On Error Resume Next
With Application
.ScreenUpdating = False
.EnableEvents = False
.DisplayAlerts = False
Dim m, d, yy, dia As Long
Dim fechafin As Date
d = Day(Now())
m = Month(Now())
yy = Year(Now())
fechafin = dia / m / yy
If Day(Now()) = 1 Then
dia = "1"
End If
Dim Mes
Mes = Month(Now())
If Month(Now()) = 7 Then
Mes = "Julio"
End If
If Month(Now()) = 8 Then
Mes = "Agosto"
End If
If Month(Now()) = 9 Then
Mes = "Septiembre"
End If
If Month(Now()) = 10 Then
Mes = "Octubre"
End If
If Month(Now()) = 11 Then
Mes = "Noviembre"
End If
If Month(Now()) = 12 Then
Mes = "Diciembre"
End If
If Date = fechafin Then
MsgBox "Debe Abrir Un Nuevo Contable para el Mes De " & Mes, vbInformation, "Recordatorio Nuevo Mes"
Call Question
End If
If Date <> fechafin Then
Ingreso.Show
End If
.ScreenUpdating = True
.EnableEvents = True
.DisplayAlerts = True
End With
End Sub
Featured Replies
Archivado
Este tema está ahora archivado y está cerrado a más respuestas.
Hola Amigos de Ayuda Excel, estoy elaborando un macro q me permita recordar una tarea a realizar en una feha determinada, pero este recordatorio se realiza una vez cada mes, yo lo estuve configurando y no se porq no me funciona, anexo dicho codigo para q por favor me ayuden a corregirlo...
de antemano muchas Gracias por su Ayuda.
Option Explicit
Private Sub Workbook_Open()
On Error Resume Next
With Application
.ScreenUpdating = False
.EnableEvents = False
.DisplayAlerts = False
Dim m, d, yy, dia As Long
Dim fechafin As Date
d = Day(Now())
m = Month(Now())
yy = Year(Now())
fechafin = dia / m / yy
If Day(Now()) = 1 Then
dia = "1"
End If
Dim Mes
Mes = Month(Now())
If Month(Now()) = 7 Then
Mes = "Julio"
End If
If Month(Now()) = 8 Then
Mes = "Agosto"
End If
If Month(Now()) = 9 Then
Mes = "Septiembre"
End If
If Month(Now()) = 10 Then
Mes = "Octubre"
End If
If Month(Now()) = 11 Then
Mes = "Noviembre"
End If
If Month(Now()) = 12 Then
Mes = "Diciembre"
End If
If Date = fechafin Then
MsgBox "Debe Abrir Un Nuevo Contable para el Mes De " & Mes, vbInformation, "Recordatorio Nuevo Mes"
Call Question
End If
If Date <> fechafin Then
Ingreso.Show
End If
.ScreenUpdating = True
.EnableEvents = True
.DisplayAlerts = True
End With
End Sub