返回列表 上一主題 發帖

[發問] 資料驗證-下拉式選單-字型大小問題

回復 2# jsc0518

請測試看看,謝謝

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
'updateby Extendoffice
On Error GoTo LZoom
Dim xZoom As Long
If Target.Column = 6 Then
xZoom = 100
If Target.Validation.Type = xlValidateList Then xZoom = 130
LZoom:
ActiveWindow.Zoom = xZoom
End If
End Sub

TOP

回復 5# jsc0518

2.假設我在 B1、F1、Z1都有下拉是選單,要怎麼改呢?
>> 請測試看看,謝謝

Private Sub Worksheet_SelectionChange(ByVal Target As Range)
On Error GoTo LZoom
Dim xZoom As Long
xZoom = 100
If Target.Address = "$B$1" Or Target.Address = "$F$1" Or Target.Address = "$Z$1" Then
If Target.Validation.Type = xlValidateList Then xZoom = 130
End If
LZoom:
ActiveWindow.Zoom = xZoom
End Sub

TOP

        靜思自在 : 有願放在心裡,沒有身體力行,正如耕田不播種,皆是空過因緣。
返回列表 上一主題