Userform Kayit

Katılım
15 Haziran 2006
Mesajlar
3,704
Excel Vers. ve Dili
Excel 2003, 2007, 2010 (TR)
Aşağıdakileri, Userform'un kod sayfasına aynen kopyalayınız.

Kod:
Private Sub CommandButton1_Click()
Set sh = Sheets("Sayfa1")
son = sh.Cells(65536, 1).End(xlUp).Row
For Each ctrl In Frame15.Controls
If TypeName(ctrl) = "OptionButton" Then
   If ctrl.Value = True Then
      sh.Cells(son + 1, 1) = ctrl.Caption
   End If
End If
Next
      sh.Cells(son + 1, 2) = TextBox16
      sh.Cells(son + 1, 3) = TextBox10
      sh.Cells(son + 1, 4) = TextBox11
For Each ctrl In Frame3.Controls
If TypeName(ctrl) = "OptionButton" Then
   If ctrl.Value = True Then
      sh.Cells(son + 1, 5) = ctrl.Caption
   End If
End If
Next
For Each ctrl In Frame4.Controls
If TypeName(ctrl) = "OptionButton" Then
   If ctrl.Value = True Then
      sh.Cells(son + 1, 6) = ctrl.Caption
   End If
End If
Next
For Each ctrl In Frame11.Controls
If TypeName(ctrl) = "OptionButton" Then
   If ctrl.Value = True Then
      sh.Cells(son + 1, 7) = ctrl.Caption
   End If
End If
Next
      sh.Cells(son + 1, 8) = TextBox4
      sh.Cells(son + 1, 9) = TextBox3
Set sh = Nothing
End Sub
 
Katılım
13 Haziran 2007
Mesajlar
110
Excel Vers. ve Dili
excel
Sayin Fbc Cok Tesekkurler
 
Üst