• DİKKAT

    DOSYA İndirmek/Yüklemek için ÜCRETLİ ALTIN ÜYELİK Gereklidir!
    Altın Üyelik Hakkında Bilgi

userform arka planını option buttonla açmak

Merhaba
Dosyanız indirilemiyor.
Şöyle yapabilirsiniz

Kod:
Private Sub UserForm_Initialize()

OptionButton1.Value = True

end sub
 
peki hocam bir sürü userform hangisi seçili şekilde kapattıysam açtığımda gene o optionbutton seçili olmasını nasıl yapıcam mesela 5 tane optionbutton var?
 
PLİNT HOCAM YAPTIM; :)

Katkıların için teşekkür ederim hocam. saygılar



Private Sub OptionButton1_Click()
Me.Picture = OptionButton1.Picture
If OptionButton1 = True Then Sheets("SYSTEM").[A1] = OptionButton1.Picture
Sheets("SYSTEM").[B1] = 1
End Sub
Private Sub OptionButton2_Click()
Me.Picture = OptionButton2.Picture
If OptionButton2 = True Then Sheets("SYSTEM").[A1] = OptionButton2.Picture
Sheets("SYSTEM").[B1] = 2
End Sub

Private Sub UserForm_Initialize()
If Sheets("SYSTEM").[B1] = 1 Then
OptionButton1 = True
ElseIf Sheets("SYSTEM").[B1] = 2 Then
OptionButton2 = True
End If
End Sub
 
Geri
Üst