ªð¦^¦Cªí ¤W¤@¥DÃD µo©«

vba½G¨­,·P®¦

¦^´_ 10# sillykin

¤£¦n·N«ä..·Q¦b½Ð°Ývba½G¨­

Private Sub OptionButton1_Click()
If OptionButton1 = True Then
[B58].VALUE = 1
[C58] = "°ê¨¾¨Æ·~"
End If
Unload Me
UserForm40.Show

End Sub

Private Sub OptionButton2_Click()
If OptionButton2 = True Then
[B58].Value = 2
[C58] = "ĵ¹î³æ¦ì"
End If
Unload Me
UserForm40.Show

End Sub

Private Sub OptionButton3_Click()
If OptionButton3 = True Then
[B58].Value = 3
[C58] = "¨ä¥L¤½¦@¦æ¬FÃþ"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton4_Click()
If OptionButton4 = True Then
[B58].Value = 4
[C58] = "±Ð¨|Ãþ"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton5_Click()
If OptionButton5 = True Then
[B58].Value = 5
[C58] = "¾Ç¥Í"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton6_Click()
If OptionButton6 = True Then
[B58].Value = 6
[C58] = "¤u¡B°Ó¤ÎªA°ÈÃþ"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton7_Click()
If OptionButton7 = True Then
[B58].Value = 7
[C58] = "¹AªLº®ªªÃþ"
End If
Unload Me
UserForm40.Show
End Sub

Private Sub OptionButton8_Click()
If OptionButton8 = True Then
[B58].Value = 8
[C58] = "Äq¥Û¤Î¤g¥Û±Ä¨ú·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton9_Click()
If OptionButton9 = True Then
[B58].Value = 9
[C58] = "»s³y·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton10_Click()
If OptionButton10 = True Then
[B58].Value = 10
[C58] = "¤ô¹q¿U®ð·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton11_Click()
If OptionButton11 = True Then
[B58].Value = 11
[C58] = "Àç³y·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton12_Click()
If OptionButton12 = True Then
[B58].Value = 12
[C58] = "§åµo¤Î¹s°â·~"
End If
Unload Me
UserForm40.Show
End Sub
Private Sub OptionButton13_Click()
If OptionButton13 = True Then
[B58].Value = 13
[C58] = "¦í±J¤ÎÀ\¶¼·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton14_Click()
If OptionButton14 = True Then
[B58].Value = 14
[C58] = "¹B¿é¡B­ÜÀx¤Î³q«H·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton15_Click()
If OptionButton15 = True Then
[B58].Value = 15
[C58] = "ª÷¿Ä¤Î«OÀI·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton16_Click()
If OptionButton16 = True Then
[B58].Value = 16
[C58] = "¤£°Ê²£¤Î¯²¸î·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton17_Click()
If OptionButton17 = True Then
[B58].Value = 17
[C58] = "±M·~ªA°È·~"
End If
Unload Me
UserForm40.Show
End Sub
Private Sub OptionButton18_Click()
If OptionButton18 = True Then
[B58].Value = 18
[C58] = "§Þ³NªA°È·~"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton19_Click()
If OptionButton19 = True Then
[B58].Value = 19
[C58] = "µL·~¡B®aºÞ¡B°h¥ð¤H­ûµ¥"
End If
Unload Me
UserForm40.Show
End Sub


Private Sub OptionButton20_Click()
If OptionButton20 = True Then
[B58].Value = 20
[C58] = "¤£°Ê«Dªk¤H²Õ´±Â«H¤á­t³d¤H"
End If
Unload Me
UserForm40.Show
End Sub
'===============================================================================





Private Sub UserForm_Click()

End Sub

TOP

¥»©«³Ì«á¥Ñ GBKEE ©ó 2016-2-14 15:38 ½s¿è

¦^´_ 11# sillykin
ªÅ¥Õªºªí³æ¼Ò²Õµ{¦¡½X
  1. Option Explicit
  2. Dim xAr(), xClass() As New OP_Class
  3. Private Sub UserForm_Initialize()
  4.      Dim xLeft As Integer, xTop As Integer, i As Integer, Form_Height As Integer, Form_Width As Integer
  5.      Dim OB As Object
  6.      xAr = Array("°ê¨¾¨Æ·~", "ĵ¹î³æ¦ì", "¨ä¥L¤½¦@¦æ¬FÃþ", "±Ð¨|Ãþ", "¾Ç¥Í", "¤u¡B°Ó¤ÎªA°ÈÃþ", "¹AªLº®ªªÃþ", "AAA", "BBBB", "CCCC", "DDDDD", "EEE")
  7.      'xAr ¤]¥i¥H¬O¤u§@ªí¤W³æÄæ©Î³æ¦Cªº½d³ò
  8.      ReDim xClass(1 To UBound(xAr) + 1)
  9.      xLeft = 10: xTop = 10
  10.      For i = 1 To UBound(xAr) + 1
  11.         Set OB = Controls.Add("Forms.OptionButton.1", "OptionButton" & i)
  12.         
  13.         Set xClass(i).Op = OB
  14.         With OB
  15.             .Caption = xAr(i - 1)
  16.             .Tag = i
  17.             .Left = xLeft
  18.             .Top = xTop
  19.             .Width = 150
  20.             .Height = 20
  21.             If i Mod 10 Then
  22.                  xTop = xTop + 10 + .Height
  23.                  Form_Height = IIf(Form_Height < xTop, xTop + 10 + .Height * 2, Form_Height)
  24.             Else
  25.                 xTop = 10
  26.                 xLeft = xLeft + 10 * 2 + .Width
  27.                 Form_Width = IIf(Form_Width < xLeft, Form_Width + xLeft + .Width, Form_Width)
  28.             End If
  29.         End With
  30.      Next
  31.      '½Õ¾ãFormªº°ª«×,¼e«×
  32.      Height = Form_Height
  33.      Width = Form_Width
  34. End Sub
½Æ»s¥N½X
ª«¥ó¼Ò²Õªºµ{¦¡½X
  1. Option Explicit
  2. Public WithEvents Op As MSForms.OptionButton
  3. Private Sub Op_Click()
  4.     'OptionButton
  5.     With Op
  6.         MsgBox .Name & vbLf & .Caption
  7.         [B58] = .Tag
  8.         [C58] = .Caption
  9.         Unload .Parent
  10.     End With
  11.     UserForm40.Show
  12. End Sub
½Æ»s¥N½X
·P®¦ªº¤ß......(¦b³Â»¶®a±Ú°Q½×°Ï.¥Î¤ß¾Ç²ß·|¦³¶i¨Bªº)
¦ý¸ê·½µL­­,«á´©¦³­­,  ¤@¤Ñ1¤¸ªºÃÙ§U,¤H¤H¦³¯à¤O.

TOP

¦^´_ 12# GBKEE


    ÁÂÁÂG¤jªº¦^ÂÐ..

TOP

        ÀR«ä¦Û¦b : ¯u¥¿ªº·R¤ß¡A¬O·ÓÅU¦n¦Û¤vªº³oÁû¤ß¡C
ªð¦^¦Cªí ¤W¤@¥DÃD