<delect id="sj01t"></delect>
  1. <em id="sj01t"><label id="sj01t"></label></em>
  2. <div id="sj01t"></div>
    1. <em id="sj01t"></em>

            <div id="sj01t"></div>

            vb語言程序設計試題庫

            時間:2024-09-01 17:53:47 計算機等級 我要投稿
            • 相關推薦

            2017年vb語言程序設計試題庫

              《VB語言程序設計》概念清晰,層次分明,敘述簡明易懂,注重實用性和可操作性。各章配有精心設計的習題和編程及上機調試題。下面是小編收集的關于vb語言程序設計試題庫,希望大家認真閱讀!

            2017年vb語言程序設計試題庫

              1.以下程序段運行的結果為(B)(單)

              Private Sub Form_Click( )

              MyDate = #7/21/1997#

              Print Format(MyDate, "m/d/yy")

              Print Format(MyDate,"yyyy年m月dd日")

              End Sub

              A.7/21/97 1997年7月21日

              B.7-21-97 1997年7月21日

              C.97/7/21 1997年7月21日

              D.7/21/97 97年7月21日

              2.以下程序段運行的結果為(B)(單)

              Private Sub Form_Click( )

              MyTime = #9:21:30 PM#

              MyDate = #7/21/1997#

              Print Tab(2); Format(MyDate, "mmmm-yy")

              Print Tab(2); Format(MyTime, "hh:mm:ss A/P")

              End Sub

              A.July-97 9:21:30 P

              B.July-97 09:21:30 P

              C.07-97 9:21:30 P

              D.July-97 9:21:30

              3.以下程序段運行的結果為(C)(單)

              Private Sub Form_Click( )

              MyDate = #7/21/1997#

              Print Format(MyDate, "dddd,mmmm,dd,yyyy")

              End Sub

              A.21,07,1997

              B.21,07,21,1997

              C.Monday,July,21,1997

              D.Monday,07,21,1997

              4.在窗體中建立一個文本框text1和一個命令按鈕command1,編寫下面程序:

              Private Sub Text1_LostFocus( )

              If Not IsNumeric(Text1) Then

              MsgBox "帳號有非數字字符錯誤"

              Text1.Text = ""

              Text1.SetFocus

              else

              MsgBox "帳號正確"

              End If

              End Sub

              當在text1文本框中輸入字符"abc"之后,單擊命令按鈕,結果為(B)(單)

              A.顯示對話框,提示信息為"帳號正確"

              B.顯示對話框,提示信息為"帳號有非數字字符錯誤"

              C.程序出錯

              D.沒有任何提示

              5.在窗體中建立一個文本框text1和一個命令按鈕command1,編寫下面程序:

              Private Sub Text1_LostFocus( )

              If Not IsNumeric(Text1) Then

              MsgBox "帳號有非數字字符錯誤"

              Text1.Text = ""

              Text1.SetFocus

              else

              MsgBox "帳號正確"

              End If

              End Sub

              當在text1文本框中輸入數字123456之后,單擊命令按鈕,結果為(A)(單)

              A.顯示對話框,提示信息為"帳號正確"

              B.顯示對話框,提示信息為"帳號有非數字字符錯誤"

              C.程序出錯

              D.沒有任何提示

              6.在窗體中建立一個文本框text1和一個命令按鈕command1,編寫下面程序:

              Private Sub Command1_Click( )

              Dim I As Integer

              If Text1.Text <> "Gong" Then

              I = MsgBox("密碼錯誤", 5 + vbExclamation, "輸入密碼")

              If I <> 4 Then

              End

              Else

              Text1.Text = ""

              Text1.SetFocus

              End If

              Else

              MsgBox "密碼帳號正確!"

              End If

              End Sub

              若在text1中輸入字符串"Gong",則程序運行結果為(A)(單)

              A.顯示對話框,提示"密碼帳號正確!"

              B.顯示對話框,提示"密碼錯誤"

              C.程序出錯

              D.沒有任何提示

              7.在窗體中建立一個文本框text1和一個命令按鈕command1,編寫下面程序:

              Private Sub Command1_Click( )

              Dim I As Integer

              If Text1.Text <> "Gong" Then

              I = MsgBox("密碼錯誤", 5 + vbExclamation, "輸入密碼")

              If I <>4 Then

              End

              Else

              Text1.Text = ""

              Text1.SetFocus

              End If

              Else

              MsgBox "密碼帳號正確!"

              End If

              End Sub

              若在text1中輸入字符串"gong",則程序運行結果為(B)(單)

              A.顯示對話框,提示"密碼帳號正確!"

              B.顯示對話框,提示"密碼錯誤"

              C.程序出錯

              D.沒有任何提示

              8.在窗體中建立一個文本框text1和一個命令按鈕command1,編寫下面程序:

              Private Sub Command1_Click( )

              Dim I As Integer

              If Text1.Text <> "Gong" Then

              I = MsgBox("密碼錯誤", VbRetryCancle + vbExclamation, "輸入密碼")

              If I <> 4 Then

              End

              Else

              Text1.Text = ""

              Text1.SetFocus

              End If

              Else

              MsgBox "密碼帳號正確!"

              End If

              End Sub

              若在text1中輸入字符串"123",顯示"密碼錯誤"對話框,關于此對話框描述正確的是(A)(單)

              A.顯示對話框中有“重試”按鈕

              B.顯示對話框中有“確定”按鈕

              C.顯示對話框中有“是”按鈕

              D.以上說法都不正確

              9.在窗體中建立三個文本框,名稱分別為text1、text2和text3,還有一個名稱為label1的標簽,一個名稱為command1的命令按鈕,編寫如下代碼:

              Private Sub Command1_Click( )

              Dim x!, y!, z!, t!

              x = Text1

              y = Text2

              z = Text3

              If x < y Then

              t = x

              x = y

              y = t

              End If

              If y < z Then

              t = y

              y = z

              z = t

              If x< y Then

              t = x

              x = y

              y = t

              End If

              End If

              Label1.Caption = x & "," & y & "," & z

              End Sub

              當在文本框text1、text2 和 text3 中分別輸入5、3和8,則標簽顯示的結果為(C)(單)

              A.3,5,8

              B.5,3,8 C.8,5,3

              D.3.8.5

              10.以下程序段:

              Private Sub Form_Load( )

              Dim Nop As Integer, Op As String * 1

              Num1 = 3

              Num2 = 2

              Nop = val(Inputbox("請輸入1-4之間的整數"))

              Select Case Nop

              Case 1

              Op = "+"

              Result = Num1 + Num2

              Case 2

              Op = "-"

              Result = Num1 - Num2

              Case 3

              Op = "×"

              Result = Num1 * Num2

              Case 4

              Op = "÷"

              Result = Num1 / Num2

              End Select

              Label1= Num1 & Op & Num2 & "=" & Result

              End Sub

              窗體運行后,輸入1,則label1的標題顯示結果為(A)(單)

              A.3+2=5

              B.3-2=1

              C.3×2=6

              D.3÷2=1.5

            【vb語言程序設計試題庫】相關文章:

            C語言程序設計學習技巧03-10

            JAVA語言程序設計練習題03-26

            學習二級c語言程序設計的方法03-10

            2016年全國計算機二級vb考試題庫及答案03-05

            2016年9月全國計算機vb二級考試題庫03-03

            全國計算機c語言程序設計題庫201703-09

            計算機二級Java語言程序設計試題03-10

            2017年計算機等級c語言程序設計試題03-09

            jQuery程序設計03-30

            <delect id="sj01t"></delect>
            1. <em id="sj01t"><label id="sj01t"></label></em>
            2. <div id="sj01t"></div>
              1. <em id="sj01t"></em>

                      <div id="sj01t"></div>
                      黄色视频在线观看