VBA Copy table columns to another table last row

Melimob

Active Member
Joined
Oct 16, 2011
Messages
396
Office Version
  1. 365
HI

I really tried (and failed) ..

I want to copy and paste from one table on one sheet... to another table on another sheet adding the data to specific columns.

I.e

Copy from:
Table11
A:J

Copy certain columns to specific columns in other table

Paste to:
Table10
B,C,E,G..

I tried to say, add a row to last row of my table
value from table11 = value to table10

It would be all the rows adding from table11 to table10

I tried with below code but no luck? any help appreciated..

Code:
Sub AddNonCCB()


Dim ABCD As Worksheet
Dim tblABC As ListObject
Dim tblrow As ListRow


Set HRGC = Sheets("ABCD Clients ")
Set tblHRG = ABCD.ListObjects(1)
Set tblrow = tblABC.ListRows.Add


tblrow.Range(1, 1).Value = Sheets("ImportNonCCB").Range("Table11[ABC Client Name]").Value


End Sub
 
Last edited:

Excel Facts

Create a chart in one keystroke
Select the data and press Alt+F1 to insert a default chart. You can change the default chart to any chart type

Forum statistics

Threads
1,225,489
Messages
6,185,283
Members
453,285
Latest member
Wullay

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