vba - Skipping a column when copying highlighted cells from one table to another in the same sheet on excel 2007? -


i have problem when copying highlighted cells table another, skip 1 column, don't know problem exactly

here code:

sub copycat()  activesheet.unprotect password:="p@ssw0rd" dim lr long, long, j long dim c range j = 1 lr = range("a" & rows.count).end(xlup).row each c in worksheets("mb").range("a15:o" & lr)       if c.interior.colorindex = 3             c.copy destination:=worksheets("mb").range("j" & j)         j = j + 1         end if next c   activesheet.protect password:="p@ssw0rd" end sub 

please me !!


Comments

Popular posts from this blog

javascript - Karma not able to start PhantomJS on Windows - Error: spawn UNKNOWN -

Nuget pack csproj using nuspec -

c# - Display ASPX Popup control in RowDeleteing Event (ASPX Gridview) -