Hello
I no know what happens for me .
I arrange the sheet by cancel merged cells and delete some columns by the first macro .after that I want creating formatting by second macro but doesn't change the FontStyle and BOLD
first macro
second macro
any help experts ,please?
I no know what happens for me .
I arrange the sheet by cancel merged cells and delete some columns by the first macro .after that I want creating formatting by second macro but doesn't change the FontStyle and BOLD
first macro
VBA Code:
Sub LoopThroughSheets()
Dim ws As Worksheet
Set ws = Sheets("sh")
ws.Range("1:1", "2:2").Delete
ws.Columns("F").Delete
ws.Columns("D").Delete
ws.UsedRange.UnMerge
End Sub
VBA Code:
Sub n()
With Sheets("sh")
.Cells(1).Resize(1, 4).Value = Array("item", "brand", "ref.no", "qty")
.Cells(1).Resize(1, 4).Font.Color = vbBlack
.Cells(1).Resize(1, 4).Font.Bold = True
.Columns("A:D").HorizontalAlignment = xlCenter
.Columns("A:D").Font.FontStyle = "Times New Roman"
.Columns("A:D").Font.Size = 12
.Columns("A:D").AutoFit
End With
End Sub