Adv VB.Net Ch 8 Quiz

10 Questions | Attempts: 224
Share

SettingsSettingsSettings
Computer Quizzes & Trivia

Questions and Answers
  • 1. 
    When performing a table lookup, it is a good idea to include validation because _______.
    • A. 

      When looking for a table it is very likely that the table will not exist

    • B. 

      The user should be notified if there is no match found in the table

    • C. 

      Validation will add a new element to the table if no match is found

    • D. 

      It will cause the lookup to perform much faster than without validation

  • 2. 
    __________ can be used to find a specific value in an array.
    • A. 

      The Find method of an array

    • B. 

      A table lookup

    • C. 

      The Locate.Item property

    • D. 

      A Case structure

  • 3. 
    How many elements are contained in the array created with the following code?                           Dim strEmployee (25) As String
    • A. 

      0 (the code is incorrect to create an array)

    • B. 

      24

    • C. 

      25

    • D. 

      26

  • 4. 
    Declare an array and specify the number of elements using _______.
    • A. 

      The ListCount property

    • B. 

      The ListIndex property

    • C. 

      An Array statement

    • D. 

      A Dim statement

  • 5. 
    The individual variables in an array are accessed by their _______, which is their position in the array.
    • A. 

      Index

    • B. 

      ListCount property

    • C. 

      Subscript

    • D. 

      ItemCount property

  • 6. 
    An array is a set of variables.  Each individual variable is called _______.
    • A. 

      A subscript

    • B. 

      An element

    • C. 

      A subscripted variable

    • D. 

      An index

  • 7. 
    _______ can be used when two subscripts are needed to identify tabular data, such as when data is arranged in rows and columns.
    • A. 

      Complex subscripts

    • B. 

      List boxes

    • C. 

      Text boxes

    • D. 

      Multidimensional arrays

  • 8. 
    When you are working with an array, the easiest way to traverse the elements is to use the _______.
    • A. 

      If / Then statement

    • B. 

      Next statement

    • C. 

      For Each / Next statement

    • D. 

      Case structure

  • 9. 
    A VB programmer can combine multiple fields of related data using a _______.
    • A. 

      DataType statement

    • B. 

      Structure statement

    • C. 

      For Each statement

    • D. 

      Public statement

  • 10. 
    If an exception is thrown and the message, “Index was outside the bounds of the array.” displays, this indicates _______.
    • A. 

      The array is completely full of data

    • B. 

      The subscript is a value greater than the number of elements declared in the array's Dim statement

    • C. 

      The subscript has reached a value lower than the number of elements declared in the array's Dim statement

    • D. 

      The answer could be B or C

Back to Top Back to top
×

Wait!
Here's an interesting quiz for you.

We have other quizzes matching your interest.