乡下人产国偷v产偷v自拍,国产午夜片在线观看,婷婷成人亚洲综合国产麻豆,久久综合给合久久狠狠狠9

  • <output id="e9wm2"></output>
    <s id="e9wm2"><nobr id="e9wm2"><ins id="e9wm2"></ins></nobr></s>

    • 分享

      用VB編寫的雙色球選號程序

       hjr231 2019-04-12

               用VB編寫的雙色球選號程序

      程序簡要介紹:

          新建一個窗體,在該窗體內(nèi)放入9個標簽控件,其中l(wèi)abel2--label8分別放入選出的號碼;有一個組合框控件,準備存入每次選中的號碼;兩個命令按鈕,分別為“開始選號”與“退出”。

      代碼如下:

      Option Explicit
      Private Sub Command1_Click()    '開始選號
         Dim q As Integer
         Dim a As Integer
         Dim b As Integer
         Dim c As Integer
         Dim d As Integer
         Dim e As Integer
         Dim f As Integer
         Dim g As Integer
        
         For q = 1 To 7
             Select Case q
                Case 1
                    Randomize (Time)
                    a = Int(Rnd * 33 + 1)
                    Label2.Caption = a
               
                Case 2
                   Do
                      Randomize (Time)
                      b = Int(Rnd * 33 + 1)
                   Loop Until b <> Label2.Caption
                   Label3.Caption = b
                  
                 Case 3
                   Do
                      Randomize (Time)
                      c = Int(Rnd * 33 + 1)
                   Loop Until c <> Label2.Caption And c <> Label3.Caption
                   Label4.Caption = c
                  
                  Case 4
                   Do
                      Randomize (Time)
                      d = Int(Rnd * 33 + 1)
                   Loop Until d <> Label2.Caption And d <> Label3.Caption And d <> Label4.Caption
                   Label5.Caption = d
        
                  Case 5
                   Do
                      Randomize (Time)
                      e = Int(Rnd * 33 + 1)
                   Loop Until e <> Label2.Caption And e <> Label3.Caption And e <> Label4.Caption And e <> Label5.Caption
                   Label6.Caption = e
        
                  Case 6
                   Do
                      Randomize (Time)
                      f = Int(Rnd * 33 + 1)
                   Loop Until f <> Label2.Caption And f <> Label3.Caption And f <> Label4.Caption And f <> Label5.Caption And f <> Label6.Caption
                   Label7.Caption = f
        
        
                  Case 7
                     Randomize (Time)
                     g = Int(Rnd * 16 + 1)
                     Label8.Caption = g
                  Case Else
               End Select
            Next q
              
                Dim w  As Variant      '在組合框內(nèi)添加選出的號碼
                   w = a & "  " & b & "  " & c & "  " & d & "  " & e & "  " & f & "--" & g
                Combo1.Text = w
                Combo1.AddItem w, 0
               
              
        
        
      End Sub

      Private Sub Command2_Click()   '退出程序
        End
      End Sub

        本站是提供個人知識管理的網(wǎng)絡存儲空間,所有內(nèi)容均由用戶發(fā)布,不代表本站觀點。請注意甄別內(nèi)容中的聯(lián)系方式、誘導購買等信息,謹防詐騙。如發(fā)現(xiàn)有害或侵權內(nèi)容,請點擊一鍵舉報。
        轉(zhuǎn)藏 分享 獻花(0

        0條評論

        發(fā)表

        請遵守用戶 評論公約

        類似文章 更多