VB.NET 2003 Test Answers



1. You are building a VB.NET application for an ISP company. The receptionist has to fill a customer registration form for dealing with walk-in customers. The form retrieves all the available products from the database into a ComboBox named "cbProducts". It uses a ListItem to add the "ProductID" and "ProductName" of each record to the combo box. The values on the form should finally be inserted into the Customer table. How will you retrieve the "ProductID" of the selected product for the update?
Answers:
• CType(cbProducts.Items(cbProducts.SelectedIndex), ComboBox).ID
• CType(cbProducts.Items(cbProducts.SelectedIndex), ListItem).Value
• cbProducts.Items(cbProducts.SelectedIndex).Value
• CType(cbProducts.Items(cbProducts.SelectedIndex), ListItem).ID

2. A programmer wrote a small function to return the sum of two bytes:
 
Public Function add(ByVal b1 As Byte, ByVal b2 As Byte) As Byte
     
        Return b1 + b2
 
End Function

What will happen when add(200, 80) is called by the program?
Answers:
• The result returned will be 280
• An exception will be thrown
• A syntax error will stop the execution
• Bytes cannot be passed by value
3. In .NET generics, the type parameter:
Answers:
• Needs to be constrained in container classes
• Needs to be constrained in all the classes
• Cannot be constrained in container classes
• Cannot be constrained in any class
4. Which of the following is not used for searching for an item within an array?
Answers:
• LastIndexOf
• IndexOf
• BinarySearch
• FirstIndexOf
5. Which of the following methods is useful for searching within a list box?
Answers:
• FindItem
• FindString
• FindItemExact
• Find
6. ____ is a subset of the CTS.
Answers:
• CLI
• CLS
• CLR
• None of these
7. You have to update some values in the database. Which method will you execute on a command object named "cmdUpdate"?
Answers:
• cmd.ExecuteScalar()
• cmd.ExecuteNonQuery()
• cmd.ExecuteReader()
• cmd.Execute()
• ExecuteXmlReader()
8. Which of the following statements is correct with regard to Windows process memory allocation?
Answers:
• Each process (instance of an application) gets its own RAM and saves the OS from crashing if the process crashes
• RAM is shared between the processes. This saves the OS from crashing when a process crashes
• Each process gets its own RAM and causes the OS to crash when the process crashes
• RAM is shared between the processes and causes the OS to crash when a process crashes
9. You have created a SQlCommand object using "con" as an open connection object:

Dim cmd as New SqlCommand("Select CategoryID, CategoryName FROM Categories", con)

Which method will you use to run the query?
Answers:
• cmd.ExecuteScalar()
• cmd.ExecuteNonQuery()
• cmd.ExecuteReader()
• cmd.Execute()
10. How many classes can a single .NET DLL contain?
Answers:
• 10
• 20
• Unlimited
• 5
11. What is a delegate?
Answers:
• A strongly typed function pointer
• A light weight thread or process that can call a single method
• A reference to an object in a different process
• An inter-process message channel
12. Code Manager is a part of:
Answers:
• CTS
• CLI
• CLS
• CLR
13. Which of the following methods is not provided with a "RichTextBox" class?
Answers:
• Cut
• Copy
• Select
• Load
• Paste
14. In .NET framework, reflection is used to:
Answers:
• Create metadata of the modules/assemblies
• Get metadata of the modules/assemblies
• Reengineer the corrupted assemblies
• Destroy the corrupted assemblies
15. The ___________  namespace is not defined in the base class library.
Answers:
• System
• System.CodeDom
• System.IO
• System.Thread
• System.Text
16. The .NET framework comes with a  few CLR hosts. Which of the following is a CLR host?
Answers:
• ASP.NET
• IE
• Shell Executables
• All of the above
17. The global assembly cache:
Answers:
• Can store two dll files with the same name
• Can store two dll files with the same name, but different versions
• Can store two dll files with the same name and same version
• Can not store dll files with the same name
18. You defined a data adapter as follows:

Dim adap As New SqlDataAdapter("select * from products;select * from customers", New SqlConnection(ConnectionString))
Dim DataSt As New DataSet
adap.Fill(DataSt)

How will you pass the data of "customers" to a data grid named as "dGrid"?
Answers:
• dGrid.Fill(DataSt.Tables(1))
• dGrid.Fill(DataSt.Tables(2))
• dGrid.DataSource = DataSt.Tables(1)
• dGrid.DataSource = DataSt.Tables(2)
19. A programmer wrote the following subroutine to calculate the area and circumference of a circle for a given radius:

Public sub SetValues(ByVal r1 As Double, ByVal r2 As Double)

If (r1 > 1 And r2 > 1) Then cir1 = (2 * Math.PI * r1): cir2 = (2 * Math.PI * r2): area1 = (Math.PI * r1 * r1)

End Sub

Here cir1, cir2 and area1 are global variables of type double. Which of the following are true with regard to the above 'if' statement?
Answers:
• If r1 > 1 then cir1=(2 * Math.PI * r1) will be executed
• If r2 > 1 then cir1=(2 * Math.PI * r2) will be executed
• If (r1 or r2) > 1 then cir1=(2 * Math.PI * r1) and cir2 = (2 * Math.PI * r2) will be executed
• If (r1 and r2) > 1 then all the three statements will be executed
20. Which of the following is not a feature of .NET 2.0?
Answers:
• Partial classes
• Generics
• Multiple Inheritance
• Partial Methods
21. How can you make a form scrollable?
Answers:
• Set its Scrollable property to true
• Set its AutoScrolling property to true
• Set its Scroll property to true
• Set its AutoScroll property to true
22. Which of the following Visual Studio projects is not available in the "New Project" dialog box?
Answers:
• Console application
• Class library
• Wireless application
• .Net web service
23. Which of the following is true for overriding?
Answers:
• The behavior of the derived class function is changed
• The behavior and name of the derived class function are changed
• The name of the derived class function is changed
• The name and arguments of the derived class function are changed
24. With VB.Net, controls can be created at run time. The statement that can be used to add events to such runtime controls is:
Answers:
• CreateHandler
• CreateEventHandler
• AddHandler
• AddEventHandler
25. You have placed an OpenFileDialog control to let users select image files. How will you set the filter to display image files only? The name of the control is "ofdImage".
Answers:
• ofdImage.Filter = "Image Files|*.BMP;*.GIF;*.JPG"
• ofdImage.Filter = "Images*;*.BMP|*.GIF|*.JPG"
• ofdImage.Filter = "*.BMP;*.GIF;*.JPG| Images"
• ofdImage.Filter = "Image Files|BMP.*;GIF.*;JPG.*"
26. Which of the following statements is correct with regard to .NET framework managed web pages?
Answers:
• They interact directly with the runtime
• They do not execute in the native code language
• They are interpreted and scripted
• All of the above
27. You have made a form named "frmEdit" with the following menu and submenu items:

File                Edit
-------------------
New                Copy
Open                Cut
Exit                Paste

The reference created for the frmEdit is "frmEd". How will you access the name of the submenu item 'Paste' within the code?
Answers:
• frmEd.Menu.MenuItems(1).MenuItems(2).Text
• frmEd.Menu.MenuItems(2).MenuItems(3).Text
• frmEd.Menu(1).MenuItems(2).Text
• frmEd.Menu(2).MenuItems(3).Text
28. What will be the result of the following code:

        Dim employeeDS As DataSet
        employeeDS.Tables.Add(new DataTable("FirstQTR"))
Answers:
• It will create a table named FirstQTR
• It does nothing because an object reference has not been set to an instance of the DataSet object
• It will produce an error because an object reference has not been set to an instance of the DataSet object
• None of the above
29. Which of the following is used as a Serializer for the web services?
Answers:
• XmlSerializer
• SoapSerializer
• BinaryFormatter
• SoapFormatter
30. Which of the following datatypes are new in Visual Basic .Net?
Answers:
• float, short
• decimal, char
• String
• Integer
31. Which of the following is not correct for using binary search with an array?
Answers:
• It is the fastest method of searching
• It works well with unsorted arrays
• It can search array lists of up to 100,000 elements or more
• It compares the search string with the middle array element
32. Consider the following small concatenation function:

Public Function concat(ByVal st1 As String, ByVal st2 As String) As String
        concat = st1 + st2
        st1 = ""
        st2 = ""
End Function


The original encrypted strings passed to the function were:

s1="James"
s2="Bond"

If the resultant string is s3, what would be the value of s1, s2, s3 after the function has been called?
Answers:
• s1="James" s2="Bond" s3="JamesBond"
• s1="James" s2="Bond" s3="James"
• s1="" s2="" s3="JamesBond"
• s1="James" s2="Bond" s3=""
33. A hashtable is serialized by using:
Answers:
• XmlSerializer or SoapFormatter
• XmlSerializer
• SoapFormatter
• XmlSerializer and SoapFormatter
34. Which of the following is not correct about DataReader?
Answers:
• It provides a forward-only and read-only row set of data from a data source
• Its CursorType property is adOpenForwardOnly
• Its LockType property is adLockReadOnly
• None of the above
35. Which of the following statements is correct with regard to a CommandBuilder object?
Answers:
• It creates update/delete commands based on the primary key column
• It creates update/delete commands based on all the identity columns
• It creates update/delete commands based on original values of all the selected columns
• It creates update/delete commands according to its internal algorithm
36. Asynchronous execution is supported in ADO.NET 2.0 for ExecuteReader, ExecuteScalar, and ExecuteNonQuery.
Answers:
• True
• False
37. Which of the following keywords does not work with methods?
Answers:
• Overridable
• NotOverridable
• MustOverride
• NonInheritable
38. Where is the shared assembly generally stored?
Answers:
• The application's directory
• Global assembly cache
• C drive
• None of the above
39. Which of the following options represents the possible values for the 'DataRowVersion' class?
Answers:
• Current, Revised, Original, Modified
• Revised, Default, Original, Modified
• Current, Default, Edited, Proposed
• Current, Default, Original, Proposed
40. Consider the following definition of a subroutine:

Public Sub SetAmount(Rate As Double, ItemCount As Integer, ItemName As String)

Which of following is the correct way to call the sub?
Answers:
• SetAmount(525.50, "CD Player", 2)
• SetAmount(2, 525.50, "CD Player")
• SetAmount(ItemCount:2, Rate:525.50, ItemName:"CD Player")
• SetAmount(Rate:=525.50, ItemName:="CD Player", ItemCount:=2)
41. Which of the following statements is not correct with regard to .NET assemblies?
Answers:
• Static assemblies can include classes, JPEG files, resource files etc.
• Static assemblies are stored on disk in PE files
• The .NET Framework can create dynamic assemblies
• Dynamic assemblies are automatically saved to disk before execution
42. You are designing a testing application where every participant has to submit his/her answers. The test takers are ranked according to the correctness of the answers. All those who score the same marks are ranked according to the quickness in submitting the answer sheet. Which collection is best for your application?
Answers:
• Stack
• Queue
• Array
• Hashtable
43. You designed a user login screen for a new management system written in VB.Net. What should be the signatures of the Login button's click event, if the button name is "bLogin"?
Answers:
• Private function bLogin_Click(ByVal sender As System.Attribute, ByVal e As System.EventArgs) Handles Button.Click
• Private Sub bLogin_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bLogin.Click
• Private Sub bLogin_Click(ByVal sender As System.Attribute, ByVal e As System.EventHandler) Throws Exception
• Private Sub bLogin_Click(ByVal sender As System.Object, ByVal e As System.EventHandler) As Button.Click
44. Which of the following is not correct for an Exception?
Answers:
• It should be handled using Try Catch blocks
• A maximum of five catch blocks can be declared
• The Finally block is optional
• You can throw new exceptions using: Throw : new Exception("description")
45. Which one of the following statements is true about MSIL code? 
Answers:
• It is compiled to native code by JIT compilers
• It is source code-specific
• It is only found in static assemblies
• It is architecture-specific
46. What is the nominal storage allocation  for the Byte data type?
Answers:
• 2 byte
• 1 byte
• 8 byte
• 16 byte
47. What does Managed Data refer to?
Answers:
• The data stored by CLR
• The data allocated by CLR GC
• The data de-allocated by CLR GC
• The data allocated and de-allocated by CLR GC
48. Which of the following is not correct with regard to DataReader and DataSet?
Answers:
• DataReader reads one row from the database
• DataSet retrieves the complete set of data from the database
• DataReader can only get its data from a data source through a managed provider
• DataReader closes its connection automatically
49. Which of the following collections exposes the capacity method?
Answers:
• HashTable
• SortedList
• ArrayList
• Stack
50. .NET Framework programs are compiled into a CPU independent instruction set named:
Answers:
• Microsoft Interpreted Language
• Microsoft Intermediate Language
• Microsoft Virtual Language
• Microsoft Common Language
51. Which of the following should you use to serialize instances of a class?
Answers:
• XMLSerializer
• It depends on the situation
• SoapFormatter
• BinaryFormatter
52. You have created a guest book which uses an XML document. Initially, the XML file is uploaded into a data table and as the records increase, the value of the 'GuestID' column should be incremented. Which properties of a column will be used to implement auto increment functionality?
Answers:
• AutoIncrementSeed
• AutoIncrementStep
• AutoIncrement
• AutoIncrementNumber
• AutoIncrementIndex
53. The code written to target common language runtime services is called:
Answers:
• Generated Code
• Managed Code
• Unmanaged Code
• CLR Code
• Service Code
54. Which of following methods is not provided by the "Directory" class?
Answers:
• GetDirectories
• GetFiles
• GetPath
• GetLogicalDrives
55. Which of the following is not correct with regard to shared assembly?
Answers:
• Its version can be controlled by the author only
• It can be shared by many applications
• It must get registered with the machine registry
• It is installed in the global assembly cache
56. In a subroutine, a programmer defined the 'for' loop as follows:

Dim count, endAt As Integer
endAt=5

For count = 0 To endAt
      If (getValue() = True) Then endAt = 10
Next

How many times will the loop execute, if the getValue() function returns true at count=0?
Answers:
• 6
• 5
• 10
• 11
57. One of your forms displays the list of all the Customers in a list box and all their details in the text boxes. On selecting a Customer from the list box, the text boxes should show details of that customer. Which of the following will be useful?
Answers:
• Me.BindingContext(DataSet,TableName).Position
• Me.BindingContext(TableName, DataSet).Position
• Me.BindingContext(DataSet,TableName)
• Me.BindingContext(TableName, DataSet)
58. Which of these files is used for debugging an application?
Answers:
• demo.dll
• demo.pdb
• demo.res
• Any of these can be used
59. You have defined a class to calculate the bonus paid to the employees of a company:

Public Class Bonus

    Public Function GetBonus(ByVal sal As Double) As Double
          Dim bonus as Double
          . . .  . .
            . . .  . .

          'Complex calculations to calculate it

        Return bonus
    End Function

End Class

Now some employees get an additional sum of $100 as special bonus on top of this. How will you design a class without changing the existing class?
Answers:
• Public class BonusMod
• Public class BonusMod Inherits Bonus
• Public class BonusMod Extends Bonus
• Public class BonusMod Overrides Bonus
60. Which of the following types of inheritance is not supported by .Net?
Answers:
• Implementation inheritance
• Multiple inheritance
• Visual inheritance
• Interface inheritance
61. What is the syntax to create a SQL connection in VB.Net?
Answers:
• Dim str As string Str = "server = ads; uid = ads ; pwd = ghf; database = bvb" Dim con as new sqlConnection(str)
• Dim str as string Str = "server = ads; pwd = ghf; database = bvb" Dim con as new sqlConnection(str)
• Dim str As string Str = "uid = ads ; pwd = ghf; database = bvb" Dim con as new sqlConnection(str)
• Dim str As string Str = "server = ads; uid = ads ; pwd = ghf" Dim con as new sqlConnection(str)
62. How many bits does the int datatype use in .NET?
Answers:
• 16 bits
• 32 bits
• 64 bits
• None of the above
63. While working with collections, sometimes it is necessary to persist objects. Which method will be suitable to store a HashTable named "hash" to a file Stream named "fileStr" using a BinaryFormatter named "BF"?
Answers:
• BF.Serialize(fileStr, hash)
• BF.SerializeGroup(fileStr, hash)
• BF.Serialize(hash, fileStr)
• BF.SerializeGroup(hash, fileStr)
64. You have an array list named "alCustomer" containing 200 items. The array list is sorted, and you want to copy customers 21 to 50 from this list to a new array list named "alSpecial". Which of the following methods will you use?
Answers:
• alSpecial.Insert(0, alCustomer.SetRange(20, 30))
• alSpecial.InsertRange(0, alCustomer.GetRange(20, 30))
• alSpecial.Add(0, alCustomer.SetRange(21, 50))
• alSpecial.Add(0, alCustomer.GetRange(21, 50))
65. Consider the following definition of an overloaded function:

Public Overloads Function Join(ByVal st As String, ByVal no As Integer) As Double
   
Which of the following does not represent a valid overloaded method with respect to the above declaration?
Answers:
• Public Overloads Function Join(ByVal str As String, ByVal num As Integer) As String
• Public Overloads Function Join(ByVal num As Integer, ByVal str As String) As String
• Public Overloads Function Join(ByVal str As String, ByVal num String) As String
• Public Overloads Function Join(ByVal str As Integer, ByVal num Integer) As Double
66. What kind of object is a string considered to be?
Answers:
• Reference
• Delegate
• Value
• Attribute
67. Which one of the following statements is true about garbage collection? 
Answers:
• It is invoked every 40 seconds until the process is destroyed
• It is invoked every time a constructor is called
• It only occurs when the Collect method is explicitly invoked in the System.GC class
• It is invoked when generation 0 does not have room for the newly created object
68. Which of these assemblies is used for doing localization?
Answers:
• Private
• Public
• Satellite
• Both Public and Private
69. ______________  is self-describing code.
Answers:
• Unmanaged Code
• Managed Code
• High Level Code
• Secured COde
70. A DataSet:
Answers:
• Can derive data from a database
• Can derive data from an XML file
• Can derive data from both an XML file and a database
• Can be used to view data only
71. You want to compile your Visual Basic .NET source code. Which command-line tool will you use?
Answers:
• csc.exe
• vbc.exe
• vbnet.exe
• vb.exe
72. Which transport protocol is used to call a Web Service?
Answers:
• SOAP
• HTTP
• SMTP
• Any of these can be used
73. Which one of the following is a value type?
Answers:
• pointer
• object
• delegate
• enum
74. Which method of the FormsAuthentication class is used to read user ids and passwords from the web.config file  automatically
Answers:
• IsAuthenticate()
• Authenticate()
• Authentication()
• HashPasswordForStoringInConfigFile()
75. Which Portable Executable (PE) file does not contain the assembly manifest?
Answers:
• Executable
• DLL
• Module
• ALL
76. Which of the following is used to return only the time of the current day?
Answers:
• Now
• TimeOfDay
• Today
• DayTime
77. Delay signing allows a shared assembly to be signed with:
Answers:
• A private key at the initial stage
• Private and public keys at the initial stage
• A private key at a later stage
• A public key at a later stage
78. You declared an object variable named 'obj'. How will you check if it is initialized or not?
Answers:
• if (obj == null) then
• if(obj) then
• if(obj is nothing) then
• if (IsNull(Obj)) then
79. Which of the following is true for the 'instance' methods?
Answers:
• They must be invoked by calling the new constructor
• Their instance is saved by the system for performance reasons
• They can be invoked by using the class name followed by the method name
• They are defined using the keyword 'instance'
80. Which of these are runtime hosts in .NET Framework?
Answers:
• CLR
• IE
• IIS
• ASP.NET
81. Which of the following are valid methods of the SqlTransaction class?
Answers:
• Commit
• Terminate
• Save
• Close
• Rollback
82. _____________ helped overcome the DLL conflict (faced by the versions prior to .NET).
Answers:
• Strong-named assemblies
• Version-aware code storage
• Components executing in isolation
• All of the above
83. Which namespace contains the DataSet class?
Answers:
• System
• System.data
• System.dataset
• System.data.dataset
84. An application reads stock listings from a text file and displays them in a combo box. Since the text file contains at least 8000 records at a given time, the default property of the combo box is set to 'sorted'. The list is cleared before each reload and the new stock listing file is loaded by the user via a load button. The user complains that loading is very sluggish. Which is the most effective and user friendly solution to address this problem?
Answers:
• Remove sorting from the combo box
• Increase the RAM of the system
• Reduce the number of file uploads
• Enable sorting on the combo box only after each load
85. What is the value range of the Boolean data type?
Answers:
• True or False
• True
• False
• 0,1
86. Which of the following helps assemblies become self describing?
Answers:
• JIT
• Manifest
• CTS
• Application Domain
87. .NET framework has data providers for:
Answers:
• ODBC and SQl Server
• Sql Server, OleDb, and ODBC
• Sql Server,OLeDb, and Oracle
• Oracle, OleDb, Sql Server, and ODBC
88. You have a table named 'FirstQTR' and want to create another table named 'SecondQTR' which is exactly the same as 'FirstQTR', including DataTable schema and constraints. Which of the following methods will fulfill this requirement?
Answers:
• Copy
• Clone
• Duplicate
• Equals
89. A class contains an overridable method "getBalance(utype as Integer)". Its derived class also has the same method, but with a different implementation. How can the parent and child classes refer to their own methods explicitly?
Answers:
• MyBase.getBalance(utype)
• MyClass.getBalance(utype)
• Me.getBalance(utype)
• This.getBalance(utype)
90. How is an assembly unloaded?
Answers:
• By using the static method Unload()
• By using the non static method Unload()
• By unloading its application domain
• By unloading CLR
91. Dot Net Framework consists of:
Answers:
• Common language runtime
• Set of class libraries
• Common language runtime and set of class libraries
• Common language runtime, set of class Libraries, and ADO.NET
92. In which file can you define the "Process Model" attribute?
Answers:
• Web.config
• Machine.config
• In both files
• In neither file
93. Which of the following benefits is not related to CLR?
Answers:
• Ability to use components developed in different language
• Garbage collection
• IDL (interface definition language) use is promoted by restricting self describing objects
• Ability to compile once and run on any computer having CLR
94. Which of the following manages the code during execution?
Answers:
• Coding Manager
• JIT
• Code Manager
• Coder Manager
95. Which of the following methods is not correct for clipping an image?
Answers:
• Graphics.SetClip(Region)
• Graphics.SetClip(Graphics)
• Graphics.SetClip(Rectangle)
• Graphics.SetClip(Square)
96. The following function is defined in a class called "StringFormatter":

Public Shared Function HasLettersOnly(ByVal str As String) As Boolean
     If (str.Length > 0) Then
         Dim i As Int64
         For i = 0 To str.Length - 1
             If Not Char.IsLetter(str.Chars(i)) Then Return False
         Next i
     End If
     Return True
End Function

How will you call this function if the string to be validated is defined as "UserString"?
Answers:
• Dim sf as new StringFormatter("UserString") sf.HasLettersOnly()
• StringFormatter.HasLettersOnly(UserString)
• Dim sf as StringFormatter(UserString) sf.HasLettersOnly(UserString)
• Dim sf as new StringFormatter(UserString) sf.HasLettersOnly()
97. How does CLR allow multiple applications to be run in a single process?
Answers:
• By running them in a special application domain
• By making sub processes for each process
• By loading them in separate application domains
• None of the above
98. Which of the following should be inserted in the constructor to refer to the super/parent class?
Answers:
• Super()
• MyParent.New()
• Super.New()
• MyBase.New()
99. You have written a function to generate a unique bill number for every new bill:

1 Public Function getNewBillNo() As Integer
2        Dim cm As New SqlCommand("select max(billno) from bill", con)
3        con.Open()
4               
5     
6 End Function

You want to return "1" as the bill number if no record exists in the database. Otherwise, the return value should be the maximum bill number plus one. What should follow in line 4, if you want to check for Null values as well?
Answers:
• Return (IIf(IsNull(cm.ExecuteNonQuery), 1, cm.ExecuteNonQuery +1))
• Return (IIf(IsDBNull(cm.ExecuteScalar), 1, cm.ExecuteScalar +1 ))
• Return (IIf(IsNull(cm.ExecuteScalar), 1, cm.ExecuteScalar))
• Return (IIf(IsDBNull(cm.ExecuteNonQuery), cm.ExecuteNonQuery ,1))
100. For MSIL code to be executed in a PE file, it is necessary to have:
Answers:
• Assembly manifest
• Modules
• Files
• Types
101. Which of the following is not associated with the command object in ADO.NET 2.0?
Answers:
• cmd.ExecuteScalar()
• cmd.ExecutePageReader()
• cmd.ExecuteReader()
• cmd.ExecuteXmlReader()
• cmd.Execute()
102. You want to open a form named 'frm' from a MDI form. This is the first line of code that you have written:

Dim frm as new ApplicationForm

Which of the following will make the form visible?
Answers:
• frm.invoke()
• frm.show()
• frm.display()
• frm.ShowModel()
103. Which of the following tools assists in Assembly Signing?
Answers:
• CASPol.exe
• PerfMon.exe
• SN.exe
• Soapsuds.exe
104. Which of the following classes is not associated with System.IO?
Answers:
• StreamReader
• BinaryWriter
• BinaryStream
• FileStream
105. You have written a simple function to multiply two integers:

Line 1 Public Function multiply(ByVal a As Int32,
Line 2                                  ByVal b As Int32) As Int32
Line 3         return (a * b)
Line 4 End Function

What will happen on running the program?
Answers:
• The program will compile and run successfully
• The compilation error produced will be fixed by changing As Int32' to 'As Integer' in line 2
• The compilation error produced will be fixed by replacing line 3 with Return CType(a * b, Int32)
• The compilation error produced will be fixed by appending "_" (underscore) to the end of line 1
106. You assigned the version number - 5.3.1.0 to your assembly.
The four digits stand for:
Answers:
• Revision, Built, Major Version, and Minor version
• Revision, Built, Minor Version, and Major version
• Built, Major version, Minor Version, and Revision
• Major version, Minor Version, Built, and Revision
107. In a list box control, the property named "SelectionMode" controls the selection of the items. Which of the following is not correct for the "SelectionMode" property?
Answers:
• MultiSimple allows multiple item selection
• MultiExtended allows extended multiple selection
• Default allows single item selection
• None prohibits any selection
108. You passed an array as an argument to the following function:

Public Function Modify(ByVal ar[] as Integer) as Boolean

What will happen to the original value of the array (ar), if the function modified the values?
Answers:
• The original value of the passed array will be modified permanently
• The original value of the passed array will not be modified
109. Which of the following is a must for a private assembly?
Answers:
• Cryptographically strong name
• Unique name
• Cryptographically light name
• Global assembly cache
110. Which of the following declarations is not valid?
Answers:
• Dim x, y, z As Integer
• Dim x As int32, y As Int32, z As int32
• Dim x%, y%, z%
• Dim a As Int32, b As Short
111. Which of the following statements about ADO.NET is not correct?
Answers:
• ADO uses recordsets whereas ADO.NET uses datasets
• The ADO navigation approach is non-sequential whereas in ADO.NET it is sequential
• Disconnected access in ADO has to be coded explicitly whereas ADO.NET handles it with the adapter
• ADO offers hierarchal recordsets for relating multiple tables whereas ADO.NET provides data relations
112. A __________ assembly can be used to deploy language-specific resources for an application.
Answers:
• Shared
• Private
• Satellite
• Public
113. Which of the following is true for "shadowing" a function belonging to the parent class?
Answers:
• The derived class must have the same method type, scope, name and parameters
• The derived class must have the same method type, scope and name
• The derived class must have the same method type and name
• The derived class must have the same name