Saltar al contenido
View in the app

A better way to browse. Learn more.

Ayuda Excel

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Ejecutar Macro al realizar nuevo Cálculo en Hoja

publicado

Tengo un problema en mi macro, ya que se ejecuta solamente al reescribir sobre la celda J23

Quisiera que se ejecute de manera automática al realizar un nuevo cálculo en la hoja, como podria solucionarlo?

Dejo mi código:

Private Sub Worksheet_Change(ByVal Target As Range)

    Dim Rango As String

    Rango = "J23"

    If Not Application.Intersect(Target, Range(Rango)) Is Nothing Then

        For i = 1 To ActiveSheet.Shapes.Count

            ActiveSheet.Shapes(i).Visible = True

            

        Next i

        

        For i = 1 To ActiveSheet.Shapes.Count

            If ActiveSheet.Shapes(i).Name = Range("J23").Text Then

                ActiveSheet.Shapes(i).Visible = False

                

                Exit For

                

            End If

            

        Next i

        

    End If

Featured Replies

publicado
Private Sub Worksheet_Calculate()

    Dim Rango As String

    Rango = "J23"

    For i = 1 To ActiveSheet.Shapes.Count
        ActiveSheet.Shapes(i).Visible = True
    Next i

    For i = 1 To ActiveSheet.Shapes.Count
        If ActiveSheet.Shapes(i).Name = Range(Rango).Text Then
            ActiveSheet.Shapes(i).Visible = False
            Exit For
        End If
    Next i

End Sub

 

publicado
  • Autor

Gracias, al usar el evento Worksheet_Calculate()  se calcula de manera automática 😁

Archivado

Este tema está ahora archivado y está cerrado a más respuestas.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.