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.

Comparar y copiar valor

publicado

Sub Macro2()

'

Dim valor As String

valor = "pedro"

Set mirango = Workbooks("Libro1").Sheets("Hoja2").Range("B7:B12")

For Each mirango In Selection.Cells

Sheets("Hoja2").Select

Range("B7:B12").Select

Selection.Copy

Sheets("Hoja3").Select

Range("B13:B18").Select

ActiveSheet.Paste

Next

End

End Sub

TENGO EN LA HOJA 2 LO SIGUIENTE

EN EL RANGO B7:B12 TENGO UNA COLUMNA DE NOMBRES ASI SIN TITULO DE ENCABEZADO

hoja2 hoja 3

PEDRO PEDRO

MARIA

JOSE

PEDRO PEDRO

MARIA

JOSE

con el codigo anterior me copia todo el rango en la hoja 3, pero yo quisiera validar al comparar un valor que yo le doy en este caso "pedro", me copie las celdas que son iguales a este valor en la hoja 3 y no todos los nombres, estoy atento a su colaboracion.

Featured Replies

publicado

Hola Ricardo, una opcion rapida y simple es aplicar un filtro y copiar.

Puedes generar el codigo con la grabadora o si prefieres sube tu libro y generare el codigo.

Debes usar etiquetas, normas del foro, cuando publiques codigos, gracias.

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.