[vba]
Sub FormatAndPreview()
Dim sSheetName As String
sSheetName = Application.VLookup(Range("K10").Value, Range("F117:G124"), 2, False)
With Sheets(sSheetName)
If sSheetName <> "" Then
.Rows.AutoFit
.PrintPreview
End If
End With
End Sub
[/vba]
[vba]
Sub FormatAndPreview()
Dim sSheetName As String
sSheetName = Application.VLookup(Range("K10").Value, Range("F117:G124"), 2, False)
With Sheets(sSheetName)
If sSheetName <> "" Then
.Rows.AutoFit
.PrintPreview
End If
End With
End Sub
[/vba]
____________________________________________
Nihil simul inventum est et perfectum
Abusus non tollit usum
Last night I dreamed of a small consolation enjoyed only by the blind: Nobody knows the trouble I've not seen!
James Thurber