Run-Time error, type Mismatch

T

T De Villiers

Cant see the problem at all, getting Run-Time error 13, Type mismatch
at asterixed line

Thanks

Sub printtariq()



Worksheets("Test").Select

'1) Number the columns

a = Cells.Find("WorkOrder").Column
b = Cells.Find("CostC").Column
c = Cells.Find("PaperSize").Column
d = Cells.Find("PaperWeight").Column
e = Cells.Find("NoBW").Column
f = Cells.Find("NoColour").Column
g = Cells.Find("printtype").Column
h = Cells.Find("x").Column


'2) Define last row and column
lastrow = Range("A65500").End(xlUp).Row
lastcol = Range("IV1").End(xlToLeft).Column

'3)
Cells(1, lastcol + 1) = "WoNo"
Cells(1, lastcol + 1).Font.Bold = True
i = Cells.Find("WoNo").Column
MsgBox i
MsgBox a
For y = 2 To 11
***Cells(y, i) = Right(Cells(y, a), Len(Cells(y, a) - 1))
Next

End Sub
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top