Private Sub Griglia(campo As Range)
With campo.Borders(xlEdgeLeft)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With campo.Borders(xlEdgeTop)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With campo.Borders(xlEdgeBottom)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With campo.Borders(xlEdgeRight)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With campo.Borders(xlInsideVertical)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
With campo.Borders(xlInsideHorizontal)
.LineStyle = xlContinuous
.Weight = xlThin
.ColorIndex = xlAutomatic
End With
End Sub
e funziona perfettamente, chiamato in questo modo, in due occasioni diverse:
Private Sub creazioneGriglia() 'CREAZIONE DELLA GRIGLIA COI BORDI Griglia Range(Cells(3, 1), Cells(Riga, 4)) End Sub...questa è per "grigliare" il Calendario;
Griglia Range("ListaNomiMese")
...e questa è per "grigliare" la lista dei nomi del mese.
Funziona!
Nessun commento:
Posta un commento