Excel VBA automatically copy entire row to different sheets based on cell value

nikzulfaizan

New Member
Joined
Oct 9, 2014
Messages
14
Hi ...My excel have multiple sheets as below:

1) Master Data
2) Region A
3) Region B
4) Region C
5) Region D

I need to have a VBA coding that will COPY entire row automatically into a respective sheet if the cell value match according to the "REGION".

Whenever changes was made in the Master Data, it should auto reflect also at the respected sheets.

Below is the sample data for your ease of reference. Hope someone can help me and thank you in advanced... ;)

SHEET : MASTER DATA
[TABLE="class: grid, width: 500, align: left"]
<tbody>[TR]
[TD="align: center"]A[/TD]
[TD="align: center"]B[/TD]
[TD="align: center"]C[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]E[/TD]
[TD="align: center"]F[/TD]
[TD="align: center"]G[/TD]
[/TR]
[TR]
[TD="align: center"]1[/TD]
[TD="align: center"]Summary [/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]2[/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[TD="align: center"][/TD]
[/TR]
[TR]
[TD="align: center"]3[/TD]
[TD="align: center"]Region[/TD]
[TD="align: center"]Name[/TD]
[TD="align: center"]Floor[/TD]
[TD="align: center"]Section[/TD]
[TD="align: center"]Cubicle[/TD]
[TD="align: center"]Department[/TD]
[/TR]
[TR]
[TD="align: center"]4[/TD]
[TD="align: center"]Region A[/TD]
[TD="align: center"]AAA[/TD]
[TD="align: center"]32[/TD]
[TD="align: center"]A[/TD]
[TD="align: center"]12[/TD]
[TD="align: center"]Audit[/TD]
[/TR]
[TR]
[TD="align: center"]5[/TD]
[TD="align: center"]Region A[/TD]
[TD="align: center"]BBB[/TD]
[TD="align: center"]23[/TD]
[TD="align: center"]C[/TD]
[TD="align: center"]23[/TD]
[TD="align: center"]Audit[/TD]
[/TR]
[TR]
[TD="align: center"]6[/TD]
[TD="align: center"]Region B[/TD]
[TD="align: center"]CCC[/TD]
[TD="align: center"]2[/TD]
[TD="align: center"]A[/TD]
[TD="align: center"]2[/TD]
[TD="align: center"]Operation[/TD]
[/TR]
[TR]
[TD="align: center"]7[/TD]
[TD="align: center"]Region C[/TD]
[TD="align: center"]DDD[/TD]
[TD="align: center"]1[/TD]
[TD="align: center"]A[/TD]
[TD="align: center"]3[/TD]
[TD="align: center"]Operation[/TD]
[/TR]
[TR]
[TD="align: center"]8[/TD]
[TD="align: center"]Region D[/TD]
[TD="align: center"]EEE[/TD]
[TD="align: center"]4[/TD]
[TD="align: center"]D[/TD]
[TD="align: center"]5[/TD]
[TD="align: center"]Admin[/TD]
[/TR]
[TR]
[TD="align: center"]9[/TD]
[TD="align: center"]Region C[/TD]
[TD="align: center"]FFF[/TD]
[TD="align: center"]2[/TD]
[TD="align: center"]C[/TD]
[TD="align: center"]11[/TD]
[TD="align: center"]Admin[/TD]
[/TR]
[TR]
[TD="align: center"]10[/TD]
[TD="align: center"]Region A[/TD]
[TD="align: center"]GGG[/TD]
[TD="align: center"]11[/TD]
[TD="align: center"]B[/TD]
[TD="align: center"]14[/TD]
[TD="align: center"]HR[/TD]
[/TR]
[TR]
[TD="align: center"]11[/TD]
[TD="align: center"]Region D[/TD]
[TD="align: center"]HHH[/TD]
[TD="align: center"]4[/TD]
[TD="align: center"]A[/TD]
[TD="align: center"]24[/TD]
[TD="align: center"]Admin[/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Whats the difference between CONCAT and CONCATENATE?
The newer CONCAT function can reference a range of cells. =CONCATENATE(A1,A2,A3,A4,A5) becomes =CONCAT(A1:A5)

Forum statistics

Threads
1,223,893
Messages
6,175,240
Members
452,621
Latest member
Laura_PinksBTHFT

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