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.

extraer valor con rango de varias columnas

publicado

Buenas tardes y agradecer cualquier ayuda sobre el tema :

Necesito extraer las filas relacionadas con un valor el cual tiene un rango de búsqueda de dos columnas, el

código creado sólo me extrae lo que aparece en la columna AT, pero necesitaría que me extrajese también

si el valor buscado aparece en la columna AU.

´

Lo he intentado con dos códigos pero no llego a conseguirlo

Opción 1- sólo me saca la columna AT

If Range("DIARIOCABAL!AT" & I) = Range("MAYORES!C4") Or ("DIARIOCABAL!AU" & I) = Range("MAYORES!C4") Then

Range("MAYORES!b" & J) = Range("DIARIOCABAL!F" & I)

Range("MAYORES!c" & J) = Range("DIARIOCABAL!B" & I)

Opción 2 - me da error de contexto en el código

If Range("DIARIOCABAL!AT:AU" & I) = Range("MAYORES!C4") Then

Range("MAYORES!b" & J) = Range("DIARIOCABAL!F" & I)

Range("MAYORES!c" & J) = Range("DIARIOCABAL!B" & I)

No puedo adjuntar fichero y no me deja ver el mensaje de error.

Featured Replies

publicado

Buenos dias Rafael.

Para quitar el error en la opción 2 hay que modificar la primera linea a:


If Range("DIARIOCABAL!AT"&I&":AU" & I) = Range("MAYORES!C4") Then
[/CODE]

espero que te sirva.

Saludos....

publicado
  • Autor

Buenos días, Quetzal

Siento mi torpeza pero algo estoy haciendo mal ya que me sigue dando error de sintaxis

If Range("DIARIOCABAL!AT" & I& ":AU" & I) = Range("MAYORES!C4") Then

gracias por el interés

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.