`
Hello Joe4,
I tried above macro, but it does not work as I want. I posted mini sheet, could you give is another try?
thanks
Hello Joe4,
I found a solution with another transition sheet and quite a few time of recording Macros:
Sub table()
'
'Clearing the old data
'
Sheets("schedule").Select
Rows("6:73").Select
Selection.Delete Shift:=xlUp
'
'Copy the data
'
Sheets("tournaments").Select
Range("P2:R54").Select
Selection.copy
'
'Filter the non blank
'
Sheets("prehod").Visible = True
Sheets("prehod").Select
Range("A1").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Application.CutCopyMode = False
Selection.AutoFilter
ActiveSheet.Range("$A$1:$C$53").AutoFilter Field:=1, Criteria1:="<>"
Range("A1:C25").Select
Selection.copy
Sheets("prehod").Select
ActiveWindow.SelectedSheets.Visible = False
'
'Paste the data and format the cells
'
Sheets("schedule").Select
Range("B6").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
With Selection.Borders(xlEdgeLeft)
.LineStyle = xlContinuous
.ColorIndex = xlAutomatic
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlEdgeTop)
.LineStyle = xlContinuous
.ColorIndex = xlAutomatic
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.ColorIndex = xlAutomatic
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlEdgeRight)
.LineStyle = xlContinuous
.ColorIndex = xlAutomatic
.TintAndShade = 0
.Weight = xlThin
End With
With Selection.Borders(xlInsideHorizontal)
.LineStyle = xlContinuous
.ColorIndex = 0
.TintAndShade = 0
.Weight = xlThin
End With
Range("C6:D61").Select
Selection.NumberFormat = "dd/mmm/yyyy"
With Selection
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlCenter
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With
Range("B6").Select
End Sub