KoE
04-20-2009, 08:06 PM
Guys,
This code copies from 1 column into the other; and for that it works fine.
However, I added some column & text formatting underneath and I believe it's not working as expected.
For Each sh In ActiveWorkbook.Sheets(Array("johor", "pulau pinang", "sabah", "sarawak", "selangor", "terengganu", "kedah", "kelantan", "melaka", "negeri sembilan", "pahang", "perak", "perlis", "ibu pejabat", "wp kl"))
With sh
LastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
For i = 1 To LastRow
If .Cells(i, "V").Value = "" Then
.Cells(i, "V").Value = .Cells(i, "O").Value
End If
Next i
Selection.Columns("V:V").ColumnWidth = 30
Selection.Columns("V:V").WrapText = True
End With
Application.ScreenUpdating = True
Next
Would be glad if someone could look, assess and/or propose tidying up of those statements in bold
Thanks :beerchug:
This code copies from 1 column into the other; and for that it works fine.
However, I added some column & text formatting underneath and I believe it's not working as expected.
For Each sh In ActiveWorkbook.Sheets(Array("johor", "pulau pinang", "sabah", "sarawak", "selangor", "terengganu", "kedah", "kelantan", "melaka", "negeri sembilan", "pahang", "perak", "perlis", "ibu pejabat", "wp kl"))
With sh
LastRow = .Cells(.Rows.Count, "A").End(xlUp).Row
For i = 1 To LastRow
If .Cells(i, "V").Value = "" Then
.Cells(i, "V").Value = .Cells(i, "O").Value
End If
Next i
Selection.Columns("V:V").ColumnWidth = 30
Selection.Columns("V:V").WrapText = True
End With
Application.ScreenUpdating = True
Next
Would be glad if someone could look, assess and/or propose tidying up of those statements in bold
Thanks :beerchug: