Copiar datos de una hoja a otra y pasar a la siguiente fila

mtamaniz

New Member
Joined
Jun 1, 2021
Messages
1
Office Version
  1. 2019
  2. 2016
Platform
  1. Windows
BUENAS NOCHES

Tengo un codigo el cual pido que me copie de una hoja llamada SOLICITUD_DE_RMA´S del rango B28:J37, lo copiara a una hoja concentradora llamada CTRL_RECTIFIC iniciando en B4 y luego pase a la siguiente linea par seguir agregando mas informacion, pero me marca un error, mi codigo es el siguiente:


Agradeceria muchisimo su valioso tiempo y apoyo, ya que no logro dar con el error............... saludos amigos

VBA Code:
Dim strTitulo As String
Dim Continuar As String
Dim TransRowRng As Range
Dim NewRows As Long      'te cambié esto porque a medida que crezca el Integer no te va a servir
Dim IColum, J As Integer
'
strTitulo = "RECTIFICADORES - CONTROL DE REPARACIONES"
Continuar = MsgBox("¿Desea dar de alta los datos?", vbYesNo + vbExclamation, strTitulo)
If Continuar = vbNo Then Exit Sub
'
J = 1
Set TransRowRng = ThisWorkbook.Worksheets("Ctrl_RECTIFIC").Cells(5, 2).CurrentRegion
NewRows = TransRowRng.Cells(Rows.Count, 2).End(xlUp).Offset(1).Row                          '<-------------MARCA EL ERROR
For IColum = 2 To 10
    For J = 1 To 10
        With ThisWorkbook.Worksheets("Ctrl_RECTIFIC")
        .Cells(NewRows, IColum).Value = ThisWorkbook.Sheets("Solicitud_de_RMA'S").Cells(28, IColum)
        .Cells(NewRows + J, IColum).Value = ThisWorkbook.Sheets("Solicitud_de_RMA'S").Cells(28 + J, IColum)
        End With
    Next J
 
Next IColum

'
MsgBox "Registro(s) Guardado(s) con Exito", vbInformation, strTitulo

NOTA: Una disculpa si no subo el archivo, pero no encontre donde se sube

solicitud.xlsm
ABCDEFGHIJKL
8
9
10CLIENTE SOLICITANTE RMA:PROVEEDOR QUE REALIZA LA REPARACION:
11RADIOMOVIL DIPSA, S.A. DE C.V.ELECTRONICS S.A. DE C.V.
12REGION:R-8CERRO DEL TESORO NO.
13ENTREGAR EL EQUIPO REPARADO EN LA SIGUIENTE DIRECCIÓN:COYOACAN C.D.M.X.
14Av. Heroes, cd mexico
15
16NOMBRE DEL RESPONSABLE:Miguel A.NOMBRE DEL RESPONSABLE:Jorge M.
17TELEFONOS:(55) 555555555TELEFONOS:TEL:(55)55555555
18E-MAIL:miguel@mail.comE-MAIL: imartinon@comsmx
19FECHA DE SOLICITUD DEL RMA:28/05/2021FECHA DE RESPUESTA DEL RMA:
20
21
22
23
24Se solicita la reparación de los equipos
25
26
27ITEMREGIONNO. SAPNOMBRE SAPNO. SERIENOMBRE DEL SITIOID DEL SITIORMA ASIGNADOFECHA ASIGNACION RMAGUIA O MODO DE ENVIO A PROVEEDOR
28186007943CC109168472 RECTIFICADOR SPS EP-1000LBLNPW15CS50170907CARDENALAS8106G850222222/02/2021
29286007943CC109168472 RECTIFICADOR SPS EP-1000LBLNPW15CS50170901CARDENALAS8106G850333323/02/2021
30386007943CC109168472 RECTIFICADOR SPS EP-1000LBLNPW14CS43120099BONANZAAS2419U850444424/02/2021
31486007943CC109168472 RECTIFICADOR SPS EP-1000LBLNPW13CS25042371TORONTOEU3786U850555525/02/2021
32586007943CC109168472 RECTIFICADOR SPS EP-1000LBLNPW13CS13028206TORONTOEU7862U850666626/02/2021
33686007943CC109168472 RECTIFICADOR SPS EP-1000LBLNPW10LD45590791TERRENO BRAVOAS6046U850777727/02/2021
34786007943CC109168472 RECTIFICADOR SPS EP-1000LBLNPW13CS23039708ALOHAAS8823U850888828/02/2021
35886007945241117.130 RECTIF MINIPACK 800W WIR171371016856MOTULAS6198U850999901/03/2021
369      
3710        
38
Solicitud_de_RMA'S
Cell Formulas
RangeFormula
E16E16='Captura Rectif.'!D1
D17D17='Captura Rectif.'!B3
C18C18='Captura Rectif.'!B2
E19E19='Captura Rectif.'!G3
F28:F37F28=IF('Captura Rectif.'!C8="","",'Captura Rectif.'!D8)
G28:G37G28=IF('Captura Rectif.'!C8="","",'Captura Rectif.'!E8)
H28:H37H28=IF('Captura Rectif.'!C8="","",'Captura Rectif.'!F8)
I28:J37I28=IF('Captura Rectif.'!G8="","",'Captura Rectif.'!G8)
C37,C28:C35C28=IF(D28="","",8)
D28:D37D28=IF('Captura Rectif.'!C8="","",'Captura Rectif.'!C8)
E37E37=IF('D:\- Control Refacciones Dañadas.xlsm]Captura Rectif.'!C17="","",VLOOKUP(D37,'D:\- Control Refacciones Dañadas.xlsm'!Tabla8[#All],2,1))


solicitud.xlsm
ABCDEFGHIJKLM
1ENVIOS RECTIFICADORES
2
3ITEMREGIONNO. SAPNOMBRE SAPNO. SERIENOMBRE DEL SITIOID DEL SITIORMA ASIGNADOFECHA ASIGNACION RMAFECHA DE ENVIOFECHA DE SOLICITUDGUIA O MODO DE ENVIO A PROVEEDOR
4
5
Ctrl_RECTIFIC
Cells with Conditional Formatting
CellConditionCell FormatStop If True
I4:L11Celldoes not contain a blank value textYES
D4:F11Celldoes not contain a blank value textYES
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.

Forum statistics

Threads
1,214,653
Messages
6,120,751
Members
448,989
Latest member
mariah3

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top