Copying Rows to new sheet based on value

Orange Womble

New Member
Joined
Oct 13, 2009
Messages
11
Hi all,
I'm trying use a macro to copy certain rows (with all formating) from one sheet to another based on the contents of column K - "Cmp" in the below extract of "Datasheet1":


<TABLE style="WIDTH: 604pt; BORDER-COLLAPSE: collapse" border=0 cellSpacing=0 cellPadding=0 width=805 x:str=""><TBODY><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 97pt; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 width=129>Installation</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 30pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=40>

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 71pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=95 x:str="Install. Item ">Install. Item </TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 72pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=96>Inst.Type</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 77pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=102>Inst. Date</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 84pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=112>Ref #</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 62pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=83>StartDt</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 63pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=84>EndDt</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; WIDTH: 48pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" width=64>Cmp</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17>R</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">AAAA</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HAA121</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39820">07/01/2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">150</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">80</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">BBBB</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HDE999</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">29-05-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">150</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17>N1</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">CCCC</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HAA050</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">21-07-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">150</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17>Q1</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">DDDD</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HKC002</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">27-02-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">171</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17>R1D</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">EEEE</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HDE007</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39971">07/06/2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">150</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17>R1E</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">FFFF</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HMP004</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">20-08-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">130</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">804</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">GGGG</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">ZAA999</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">26-02-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">910441/002</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39815">02/01/2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">31-01-2010</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">160</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17>4LCN</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HHHH</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HKC002</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">25-03-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">150</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">704</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">IIII</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="9999999999">9999999999</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">19-01-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">740359/001</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39814">01/01/2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">31-12-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">140</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">1048</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">JJJJ</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">ATERM</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">25-05-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">140</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">5719</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">KKKK</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">ZAA999</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">27-04-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">920020/001</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39457">10/01/2008</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">30-09-2010</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">160</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">5773</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">LLLL</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">ZAA999</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl25>27-04-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">920020/001</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39457">10/01/2008</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">30-09-2010</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">160</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">7720</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">MMMM</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">ZAA999</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">27-04-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">920020/001</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39457">10/01/2008</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">30-09-2010</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">160</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">10095</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">NNNN</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HGE007</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">14-05-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">180</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">155749</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">OOOO</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HCA017</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">25-03-2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">C00609/002</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">26-03-2010</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">25-03-2012</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">150</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="">4834873</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">PPPP</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HDE004</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39814">01/01/2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">612718/001</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39448">01/01/2008</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="39448">01/01/2008</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">120</TD></TR><TR style="HEIGHT: 12.75pt" height=17><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; HEIGHT: 12.75pt; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" height=17 align=right x:num="8532200800276">8.5322E+12</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">QQQQ</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)">HDB064</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" class=xl24 align=right x:num="40149">02/12/2009</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" x:str=" ">

</TD><TD style="BORDER-BOTTOM: rgb(236,233,216); BORDER-LEFT: rgb(236,233,216); BACKGROUND-COLOR: transparent; BORDER-TOP: rgb(236,233,216); BORDER-RIGHT: rgb(236,233,216)" align=right x:num="">160</TD></TR></TBODY></TABLE>

(I know some of the dates and things appear a little odd and all columns aren't shown here - but i have that all sorted in reality :))

I would like to copy all of the rows where "Cmp"=160 to another sheet that is already set up with the headers in row 1 [Let's call it Belgium as that makes me smile:p]

Not sure if these bits of info help- but they may save me coming back and annoying further:
The data only runs through columns A-K (though I think I'm happy if I paste the whole row)
I will need to repeat this through 3 or more sheets titled "DataSheet?" where ? increases with the number of sheets my earlier data input pulled in. {I'm thinking to just repeat after checking for a given worksheet name but some folks here are bright enough to build it all in i think} pasting all the rows found onto the "Belgium" sheet.
I will also need to create somthing to catch any errors [ie <>130 & <>140 & <> 150 & <>180.....] I'm sure you get the idea.

I thought of sorting and copying sections at a time... but that seems cumbersome and I can't figure out how to "select rows unitl colum K changes"....:confused:

Many thanks for any suggestions :pray:
 
Last edited:

Some videos you may like

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.

JShaper

New Member
Joined
Oct 19, 2009
Messages
19
basically here is what i would do
Code:
Dim curr As Worksheet
curr = ActiveSheet
cntr = 2
For i = 1 To 10000
    If Cells(i, 11).Value = 150 Then
        Rows(i & ":" & i).Select
        Selection.Copy
        Sheets("copytohere").Activate
        Cells(cntr, 1).Select
        Selection.pate
        curr.Activate
        cntr = cntr + 1
    End If
Next i

Hope that is what you were looking for...
 

Orange Womble

New Member
Joined
Oct 13, 2009
Messages
11
Thanks JShaper

a great start - [a few minor debugs and the code is doing what I need].

Code:
Dim curr As Worksheet
Set curr = ActiveSheet
cntr = 2
For i = 1 To 1000
    If Cells(i, 11).Value = 150 Then
        Rows(i & ":" & i).Select
        Selection.Copy
        Sheets("Belgium").Activate
        Cells(cntr, 1).Select
        ActiveSheet.Paste
        curr.Activate
        cntr = cntr + 1
    End If
Next i
I'll get to tweeking it with variables in due course

Cheers
 

Watch MrExcel Video

Forum statistics

Threads
1,123,166
Messages
5,600,095
Members
414,362
Latest member
elFary

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
Top