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

[µo°Ý] ¦p¦ó¨Ï¥ÎClick°Ñ·Ó

[µo°Ý] ¦p¦ó¨Ï¥ÎClick°Ñ·Ó

Private Sub Label1_Click()
Select Case ComboBox1.Value
case "XXX"

Private Sub Label2_Click()
Select Case ComboBox2.Value
case "XXX"


¥Ñ©óLabel1ªºcase "XXX"©MLabel2ªºcase "XXX"
¥Bcase "XXX"«D±`ªº¦h~§Ú¥t¥~¶}¤F¤@­ÓModule1¤º®e¦p¤U
Sub Search()
case "XXX"

µM«á§ï¼gLabel1©MLabel2ªº¤º®e~¦p¤U
Private Sub Label1_Click()
Select Case ComboBox1.Value
case "XXX"

Private Sub Label2_Click()
Select Case ComboBox2.Value
Call Search

¦ý¬O«o¥X²{½sĶ¿ù»~:"¦bSelect Case »P²Ä¤@­ÓCase³¯­z¦¡¶¡¡A¦³¤£¥¿½Tªº³¯­z¦¡©Î¼ÐÅÒ

¨C­Ó¨Æ¥ó³£¥u¦³case "XXX"

µM«á¨S¤U¤å¤F¡H

TOP

¦^´_ 2# chin15

§Ú¤j·§±Ô­z¤@¤U~¼È®ÉA.B.C¥Nªí~¦ý¬O¤£¥u3­Ó~¨ì¥Ø«e¬°¤î¦³50¦h­Ó

Private Sub Label1_Click()
Select Case ComboBox1.Value
case "A"
UserForm1.Hide
UserForm2.Show
case "B"
UserForm1.Hide
UserForm3.Show
case "C"
UserForm1.Hide
UserForm4.Show

Private Sub Label2_Click()
Select Case ComboBox2.Value
case "A"
UserForm1.Hide
UserForm2.Show
case "B"
UserForm1.Hide
UserForm3.Show
case "C"
UserForm1.Hide
UserForm4.Show

¥Ñ©óLabel1ªºcase "XXX"©MLabel2ªºcase "XXX"
¥Bcase "X"«D±`ªº¦h~§Ú¥t¥~¶}¤F¤@­ÓModule1¤º®e¦p¤U
Sub Search()
case "A"
UserForm1.Hide
UserForm2.Show
case "B"
UserForm1.Hide
UserForm3.Show
case "C"
UserForm1.Hide
UserForm4.Show

µM«á§ï¼gLabel1©MLabel2ªº¤º®e~¦p¤U
Private Sub Label1_Click()
Select Case ComboBox1.Value
Call Search

Private Sub Label2_Click()
Select Case ComboBox2.Value
Call Search

¦ý¬O«o¥X²{½sĶ¿ù»~:"¦bSelect Case »P²Ä¤@­ÓCase³¯­z¦¡¶¡¡A¦³¤£¥¿½Tªº³¯­z¦¡©Î¼ÐÅÒ

TOP

¤Ó°ª²`¤F¬Ý¤£À´¡A³q±`·|¥Îª«¥óÃþ§O¼Ò²Õ³B²z³oÃþ¨Æ¥ó¡C§A³o¼Ëª±ªk¤@©w¦³§A¯S®íªº¥Øªº¡C

TOP

¥»©«³Ì«á¥Ñ luhpro ©ó 2012-9-10 21:00 ½s¿è
¦^´_  chin15

§Ú¤j·§±Ô­z¤@¤U~¼È®ÉA.B.C¥Nªí~¦ý¬O¤£¥u3­Ó~¨ì¥Ø«e¬°¤î¦³50¦h­Ó

Private Sub Label1_C ...
av8d µoªí©ó 2012-9-10 09:10

³o¼Ëªºµ{¦¡¼gªk½T¹ê¬O·|¦³°ÝÃDªº.

­º¥ý,
¨C­Óµ{§Ç³£¥²¶·¦³ÀY¦³§À,
¤£¯à¥u¦³°_ÂI¦Ó¨S¦³²×ÂI.
©Ò¥H¦b ¨â­Ó Sub ¶¡¥²©w­n¦³¤@­Ó End Sub ¥H«ü©ú«e¤@­Ó Sub ¤w¸gµ²§ô,
¦Ó³Ì«á¤@­Ó Sub ¤U¤è¤]¤@¼Ë­n¦³¤@­Ó End Sub «ü©ú¨ä²×ÂI.

¨ä¦¸,
Select Case ©³¤U,
¤£¦ý­n¦³¤£©w¼Æªº Case ªí¥Ü¿ï¾Ü»P¤À¤ä³B²z,
§ó­n¦³ªí©ú Select ¤w¸gµ²§ôªº End Select.

¦b§A³Ì«áªº¨º­Óµ{¦¡¤¤,
¨Ã«D¥u©I¥s°Æµ{§Ç´N¦n,
ÁÙ­n§â Select Case ªº°Ñ¼Æ¶Ç¹L¥h,
³o¼Ë°Æµ{§Ç¤¤ªº Select Case ¤~¯à¦³³B²zªº¨Ì¾Ú.
¦P¼Ëªº,
¨C­Óµ{§Ç³£¤£¯à¦³ÀY¨S§À,
Select Case «á¤]¤£¯à¨S¦³ Case »P End Select.

¬G­×§ï¦p¤U :
  1. Private Sub Label1_Click()
  2.   Call Search(ComboBox1.Value)
  3. End Sub

  4. Private Sub Label2_Click()
  5.   Call Search(ComboBox2.Value)
  6. End Sub
½Æ»s¥N½X
  1. Public Sub Search(Val)
  2.   Select Case Val
  3.     Case "A"
  4.       UserForm1.Hide
  5.       UserForm2.Show
  6.       
  7.     Case "B"
  8.       UserForm1.Hide
  9.       UserForm3.Show
  10.       
  11.     Case "C"
  12.       UserForm1.Hide
  13.       UserForm4.Show
  14.   End Select
  15. End Sub
½Æ»s¥N½X
¥t¥~,­Y¬Û¦Pªºª«¥ó«Ü¦h,
«Øij¹B¥Î°ÊºA©Î¬O°}¦C¨Ó«Ø¥ßª«¥ó,
³o¼Ëµ{¦¡·|¤ñ¸û¦n¼g.

TOP

        ÀR«ä¦Û¦b : ¶¢¤HµL¼Ö½ì¡A¦£¤HµL¬O«D¡C
ªð¦^¦Cªí ¤W¤@¥DÃD