VBA Copy columns with non-similar header name between two workbooks

AbdulkareemAlhassni

New Member
Joined
Nov 16, 2018
Messages
41
Hi there,

how can i make a condition to copy then insert a column to another workbook,

the only condition is that, if this columnd header exists in the current workbook dont copy it !

EXAMPLE:

workbook1

NameAgeCityEmail

<tbody>
</tbody>

Workbook2


NameTitleAgeSalary

<tbody>
</tbody>

so when i copy from "Workbook2" to "Workbook1" ==> i will get

New Workbook1

NameTitleSalaryAgeCityEmail

<tbody>
</tbody>


hope am clear :)

thank you.:biggrin:
 

AbdulkareemAlhassni

New Member
Joined
Nov 16, 2018
Messages
41
Hi there,

how can i make a condition to copy then insert a column to another workbook,

the only condition is that, if this columnd header exists in the current workbook dont copy it !

EXAMPLE:

workbook1

NameAgeCityEmail

<tbody>
</tbody>

Workbook2


NameTitleAgeSalary

<tbody>
</tbody>

so when i copy from "Workbook2" to "Workbook1" ==> i will get

New Workbook1

NameTitleSalaryAgeCityEmail

<tbody>
</tbody>


hope am clear :)

thank you.:biggrin:
One important thing that

Name and age should be a way to copy the data from the other columns !
 

AbdulkareemAlhassni

New Member
Joined
Nov 16, 2018
Messages
41
Hi there,

how can i make a condition to copy then insert a column to another workbook,

the only condition is that, if this columnd header exists in the current workbook dont copy it !

EXAMPLE:

workbook1

NameAgeCityEmail

<tbody>
</tbody>

Workbook2


NameTitleAgeSalary

<tbody>
</tbody>

so when i copy from "Workbook2" to "Workbook1" ==> i will get

New Workbook1

NameTitleSalaryAgeCityEmail

<tbody>
</tbody>


hope am clear :)

thank you.:biggrin:
am really stuck here
x(

please help
 

Forum statistics

Threads
1,078,231
Messages
5,338,986
Members
399,274
Latest member
WilliamWavehill

Some videos you may like

This Week's Hot Topics

Top