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.

Copiar rango de celdas a tabla

publicado

Hola buenas tardes .

Me llamo gustavo soy nuevo en este foro , gracias por aceptarme en este foro espero aprender estos conocimientos  de excel .

hay os dejo una problema que no puedo solucionar haber si alguien me puede echar una mano , el problema es que quiero copiar de la hoja NOTAS DE ENTREGA  a  una tabla que hay en la hoja NOTAS , el problema es que e echo una macro que me pega los datos pero en la hoja NOTAS tengo en la columna D y E notas que yo escribo a mano y cuando en los datos que hay en la columna C y D de la hoja NOTAS DE ENTREGA inserto algun dato cuando ejecuto la macro y copia los datos los datos que e copiado a mano en la fila D y E de la hoja notas se desplazan y no se corresponden ya los datos , no se si hay alguna manera de que solo inserte en la ultima fila los datos nuevos o  algo así , gracias de ante mano 

PRUEVAS COPIAR (2).xlsm

Featured Replies

publicado
  • Autor
hace 40 minutos , Gerson Pineda dijo:

Hola

Prueba asi, para la ultima fila

uf = h2.Range("A" & Rows.Count).End(xlUp).Row + 1

 


Sub copiar_pegar_notas()
'Evita el parpadeo de la macro
Application.ScreenUpdating = FalseAM
Set h1 = Sheets("FECHA ENTREGA")
Set h2 = Sheets("NOTAS")
j = 2
For i = 2 To h1.Range("C" & Rows.Count).End(xlUp).Row
    If h1.Cells(i, "B") > 0 Then
        h1.Range("C" & i & ":D" & i).Copy h2.Range("A" & j)
        h1.Range("D" & i).Copy: h2.Range("B" & j).PasteSpecial xlPasteValues
        'h1.Range("E" & i).Copy: H2.Range("C" & j).PasteSpecial xlPasteValues
        'h1.Range("K" & i).Copy: H2.Range("L" & j).PasteSpecial xlPasteValues
         uf = h2.Range("A" & Rows.Count).End(xlUp).Row + 1
        Application.CutCopyMode = False
        j = j + 1
     uf = h2.Range("A" & Rows.Count).End(xlUp).Row + 1
    End If
Next

MsgBox ("registros copiados"), vbInformation, "AVISO"
End Sub

 

seria asi?

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.