C# programming Test Questions.txt

  1. Which control enhances error-handling capability by providing additional functionality to report errors using a validation style similar to that commonly implemented in Internet applications?
  2. What does a SqlConnection object represent?
    A connection to a unique session with a SQL Server data source
  3. Can you use declarative code access security to request permissions for the entire assembly?
    Yes. You can use RequestMinimum
  4. Which property of the SqlException class returns the severity level of the error?
  5. What happens when a TraceSwitch's constructor cannot find initial switch settings in a configuration file?
    The Level of the new switch is set to TraceLevel. Off.
  6. Which overloaded method of an EventLog writes information to the specified log?
  7. What is a connection string?
    A string that includes the source database name and other parameters needed to create a connection to a database.
  8. Question: For which purpose would you set the DefaultItem property of a menu item?
    Answer: To identify that menu item as the default menu item. The menu item will be displayed in bold.
  9. Question: What does the Form.Activate method do?
    Answer: It activates the form and gives the form focus.
  10. Question: Which component compiles MSIL to native code on an as-needed basis?
    Answer: JIT (Just-in-Time) compiler
  11. Question: Which Visual Studio .NET deployment feature would you use to evaluate a condition on a target computer and to halt installation if the condition is not met?
    Answer: Launch condition
  12. Question: Why would you implement IDisposable and override the Dispose method?
    Answer: to perform application-specific tasks associated with freeing
  13. Question: Which isolation level provides the highest degree of protection against data concurrency errors?
    Answer: Serializable
  14. Question: Which property would you use to configure the tab order of controls on a form?
    Answer: TabIndex
  15. Question: When initiating a database transaction using the BeginTransaction method
    which isolation level could you use to allow other users to update the data
  16. Question: What is one advantage of using theWindows Installer technology in your applications?
    Answer: The .msi files andWindows Installer technology allow you to create an application setup that provides customized installation options.
  17. Question: Which form property will allow you to attach a context-sensitive pop-up menu to a form?
    Answer: ContextMenu
  18. Question: Which form property specifies whether or not the Maximize button is displayed in the title bar of the form?
    Answer: MaximizeBox
  19. Question: Where do you enable or disable tracing in a release version of your application?
    Answer: in the .config file for the application
  20. Question: Which utility would you use to customize the dialog boxes that the users see when they install your application on their computers?
    Answer: User Interface Editor
  21. Question: Why would you use DataTable.Columns.Add?
    Answer: to add a column to a DataTable
  22. Question: Which setup project property is displayed for the Contact field in the Support Info dialog?
    Answer: Author
  23. Question: Why would you use the Trace.Listeners.Add method?
    Answer: to enable a listener to retrieve trace output by adding it to the Listeners collection
  24. Question: Which method of the IPrincipal interface determines if the current security principal belongs to a specific role?
    Answer: IsInRole
  25. Question: Which collection allows you to create simple data binding with a control?
    Answer: DataBindings
  26. Question: What does sn.exe do?
    Answer: Sn.exe (the Strong Name tool) is most commonly used to create a public/private key pair for a strong-named assemblies.
  27. Question: WhichWindows Installer feature allows you to run code at the end of an installation to perform actions that cannot be handled during installation?
    Answer: Custom actions
  28. Question: Which namespace implements a principal object representing a particular security context?
    Answer: System.Security.Principal
  29. Question: Which Property Attribute will supply a default value for a property of a custom control at design time?
    Answer: [DefaultValue( )]
  30. Question: Which accessibility property of a control identifies the control to accessibility aids?
    Answer: AccessibleName
  31. Question: Which form property would you set to yes for an application written in a language that is written from right to left?
    Answer: RightToLeft
  32. Question: What is the maximum number of destructors a class can have?
    Answer: One
  33. Question: When does the EndPrint event of a PrintDocument fire?
    Answer: after the last page of the document has printed
  34. Question: Which tool converts a COM type library into equivalent definitions in a common language runtime assembly?
    Answer: Tlbimp.exe (the Type Library Importer)
  35. Question: Which two classes can you use to implement trace switches in your application?
    Answer: BooleanSwitch and TraceSwitch
  36. Question: Why would you modify theQueryPageSettingEventArgs.PageSettings property?
    Answer: to change the page settings for a single page in a PrintDocument object
  37. Question: Which Garbage Collector method can you call to force garbage collection?
    Answer: Collect
  38. Question: Can you debug a class library directly?
    Answer: No. A class library compiles to a .dll.
  39. Question: To which value would you set the Compression property in the Deployment Project Properties dialog box if you wanted to compress the files as much as possible?
    Answer: Optimize for size
  40. Question: Why would you use the ShowHelp method of the Help object?
    Answer: to display an HTML help file for a given URL
  41. Question: Which property of a Timer object contains the time between timer ticks?
    Answer: Interval
  42. Question: A ______ contains resources for a single culture and no executable code.
    Answer: satellite assembly
  43. Question: Which term refers to an assembly that is used by only one application?
    Answer: private assembly
  44. Question: What can be included in a satellite assembly?
    Answer: only resources
  45. Question: Which Transact-SQL statement can you use to prevent the number of records affected by a SQL statement from being returned?
    Answer: SET NOCOUNT ON
  46. Question: When does the ControlAdded event fire?
    Answer: when a new control is added to Control.ControlCollection
  47. Question: What displays in the Hit Count column of the Breakpoints window?
    Answer: any hit counters that have been established to limit the number of times the breakpoint is executed
  48. Question: Which class represents a view over a DataTable object?
    Answer: DataView
  49. Question: Which method of inserting breakpoints gives you the ability to configure additional options for the breakpoint?
    Answer: choosing New Breakpoint from the Debug menu
  50. Question: What is the primary purpose of a Merge Module Setup project?
    Answer: to deploy shared components and ensure correct versioning of components
  51. Question: Which property of a control indicates to which edge of the control's container the control is docked?
    Answer: Dock
  52. Question: To what does the term code access security refer?
    Answer: the process of verifying that all application users have the appropriate permissions to reference specific code in an application
  53. Question: Satellite assemblies are compiled from .resources files using which command-line tool?
    Answer: Al.exe (the Assembly Linker)
  54. Question: Which SqlCommand object property specifies the SqlConnection for the command?
    Answer: Connection
  55. Question: What does the ExecuteReader method of a Command object return?
    Answer: a DataReader object
  56. Question: Which construct would you use to implement custom error-handling in a C# .NET application?
    Answer: try...catch...finally
  57. Question: Which noninheritable class represents a Transact-SQL transaction?
    Answer: SqlTransaction
  58. Question: Which object is supported in role-based security and represents the identity and role that a principal must have to run?
    Answer: PrincipalPermission
  59. Question: Which .NET Framework tool would you use to digitally sign an assembly with an Authenticode digital signature?
    Answer: signcode.exe
  60. Question: Which property can you set to bind a property of a control to the property of an object?
    Answer: the DataBindings property of the control
  61. Question: What is the purpose of the AccessibleRole property?
    Answer: The AccessibleRole property describes what kind of user interface element an object is.
  62. Question: Which code access security permission must an assembly request in order to read and write files?
    Answer: FileIOPermission
  63. Question: Which exception class implements the exceptions returned by SQL Server?
    Answer: SqlException
  64. Question: Which types of executable code can be run in a custom action at the end of an installation?
    Answer: a .dll
  65. Question: Which class implements objects that describe a set of code security permissions?
    Answer: SecurityPermission
  66. Question: Which two tools can you use to view the contents of your application's event log?
    Answer: You can use Server Explorer from Visual Studio .NET or use the Event Viewer of MMC.
  67. Question: Which two attributes can you use with code groups in a security policy configuration file to affect how the CLR derives a final permission set for assemblies?
    Answer: LevelFinal and Exclusive
  68. Question: Which command would you use to read an application configuration setting from a .config file?
    Answer: System.Configuration.ConfigurationSettings.AppSettings.Get()
  69. Question: Which tool would you use to debug a stored procedure call in your .NET application?
    Answer: Server Explorer
  70. Question: Which code group attribute causes code access policies in lower policy levels to be ignored?
    Answer: LevelFinal
  71. Question: Which method of a SqlCommandBuilder object would you use to populate an associated SqlCommand object's Parameters collection with parameter information for the specified stored procedure?
    Answer: DeriveParameters
  72. Question: Which type of principal would you use if you had complex application logic that needed to determine access?
    Answer: Custom principals
  73. Question: What does setting the UseMnemonic property of a Label to true do?
    Answer: It indicates that an ampersand character (&) in the Label's Text property will be interpreted as an access key prefix character.
  74. Question: Which DataGrid method can be called at run time to set the DataSource and DataMember properties?
    Answer: SetDataBinding
  75. Question: Which object would you use instead of an XmlTextReader if you wanted to validate the data using schema files while reading?
    Answer: XmlValidatingReader
  76. Question: What must be done to aWeb service for its methods to be called asynchronously?
    Answer: Nothing.When you create the proxy class for aWeb service
  77. Question: When does the PrintPage event of a PrintDocument fire?
    Answer: when the output to print for the current page is needed
  78. Question: Can satellite assemblies contain intermediate language code to be executed by the common language runtime?
    Answer: No
  79. Question: What is the default name of the object variable that is passed into an event procedure and gives you access to the properties of the object that caused the event?
    Answer: sender
  80. Question: Which method of the DataAdapter writes changes in a DataSet back to the database?
    Answer: Update
  81. Question: When using a SqlDataReader to read data from a SQL Server database
    which property of the SqlDataReader could you examine to determine the number of rows changed
  82. Question: Which form property specifies whether or not the Minimize button is displayed in the title bar of the form?
    Answer: MinimizeBox
  83. Question: What is a requirement of assemblies when they are used by COM applications on a computer?
    Answer: They must be registered in theWindows Registry for the COM components to gain access to the classes.
  84. Question: Which file name extension doWindows Installer files have?
    Answer: .msi
  85. Question: Can an application configuration file be used to tell an existing application to use a new version of a shared assembly without rebuilding the application?
    Answer: Yes
  86. Question: Which class determines the permission for code based on zones configured in Microsoft Internet Explorer?
    Answer: ZoneIdentityPermission
  87. Question: When does the Form.Load event fire?
    Answer: before a form is displayed for the first time
  88. Question: Which identity object would you use to have your application useWindows authentication?
    Answer: WindowsIdentity
  89. Question: Which ErrorProvider method can you use to display an error icon with an associated ToolTip containing an error message beside a specific control?
    Answer: SetError
  90. Question: Which two steps can you take to conditionally compile blocks of code in an application?
    Answer: 1. Add a conditional compilation constant either in the Conditional Compilation Constants dialog or by using #define.2. Include the blocks to be conditionally compiled within the #if...#endif preprocessor directives.
  91. Question: Why would you add Trace listeners to your application?
    Answer: Trace listeners are used to collect error
  92. Question: From which class in the .NET Framework is the Form class derived?
    Answer: ContainerControl
  93. Question: What is an assembly?
    Answer: An assembly is the main unit of deployment for a .NET application. This could be an EXE or a DLL.
  94. Question: What is assembly redirection?
    Answer: the process of forcing an application to use one version of an assembly over another
  95. Question: Which form property can be used to make an entire form transparent?
    Answer: Opacity
  96. Question: Which property should you use to bind a table in a DataSet to a control?
    Answer: DataSource
  97. Question: Which class does the TraceSwitch class immediately inherit from?
    Answer: Switch
  98. Question: Which type of setup project would you use to deploy aWeb application to aWeb server?
    Answer: Web Setup Project
  99. Question: Can imperative security be used to perform a security demand at the class level?
    Answer: No
  100. Question: Which object controls the interaction between the DataSet object and the underlying database?
    Answer: DataAdapter
  101. Question: For an enabled Timer object
    when does the Tick event occur?
  102. Question: Can you have more than one event handler for a given event?
    Answer: Yes
  103. Question: Which property indicates to the .NET Framework whether or not there are more pages to print in a PrintDocument?
    Answer: PrintPageEventArgs.HasMorePages
  104. Question: Which utility is provided with Visual Studio .NET and allows you to add assemblies to the Global Assembly Cache?
    Answer: Gacutil.exe
  105. Question: Why would you use the Value property of a SqlParameter object?
    Answer: to specify the value of an input parameter to be passed to a stored procedure or to retrieve the value of an output parameter returned by a stored procedure
  106. Question: Which property can you set to True to terminate a cancelable event?
    Answer: Cancel
  107. Question: Which method of a SecurityPermission object would you use to create a new permission object with the characteristics common to two other permission objects?
    Answer: Intersect
  108. Question: Which .NET Framework utility can you use to discoverWeb services from a specified URL?
    Answer: Disco.exe
  109. Question: Which method do you call to run under the security context of a different Windows account?
    Answer: WindowsIdentity.Impersonate()
  110. Question: What is the purpose of the Call Stack window?
    Answer: to display the routines that have been called in the application and in what order they were called
  111. Question: Which type security would you typically use to configure security for an entire assembly?
    Answer: declarative
  112. Question: Which tool can you use with aWeb service class's description file to generate a proxy class for theWeb service?
    Answer: Wsdl.exe
  113. Question: Which code access security policy has the broadest scope?
    Answer: enterprise
  114. Question: Do breakpoints work in a Release configuration of an application?
    Answer: Yes. Breakpoints work in Debug configurations or in Release configurations that have project properties set to generate debug information.
  115. Question: Where do you set debugging options for your project?
    Answer: from the Debugging option of the Configuration Properties folder in the Project Properties dialog box
  116. Question: Which class provides data for a cancelable event?
    Answer: CancelEventArgs
  117. Question: Can custom controls only be created in Class Library assemblies which compile to .dll files?
    Answer: No
  118. Question: If you want to debug a remote application running on another computer
    which service must be running on the remote computer?
  119. Question: Which two types of principals could be used to represent users and roles other thanWindows NT andWindows 2000 users and roles?
    Answer: Generic principals and Custom principals
  120. Question: What is the purpose of conditions in breakpoints?
    Answer: to cause the breakpoint to halt application execution if the condition evaluates to true instead of always breaking
  121. Question: Which method does a destructor implicitly call?
    Answer: the Object.Finalize method of the object's base class
  122. Question: Which object would you use to read a forward-only stream of rows from a SQL Server database?
    Answer: SqlDataReader
  123. Question: Which method of a SqlDataAdapter object can you use to load a DataSet with data?
    Answer: Fill
  124. Question: What is the purpose of breakpoints?
    Answer: to pause an application for debugging purposes so that you can test variables or follow the execution of your application
  125. Question: What does the Trace.Flush method do?
    Answer: It flushes the output buffer and causes any buffered data to be written to the Listeners.
  126. Question: What is the purpose of the Custom Actions Editor?
    Answer: to manage custom actions in a deployment project
  127. Question: To store a database connection string in a configuration file
    you would add an element as a child of which element?
  128. Question: Which property would you use to set the width of a form?
    Answer: Size.Width
  129. Question: Which type of module is recommended for DLLs or other components that are likely to be only used by developers as opposed to end users?
    Answer: Merge Module
  130. Question: A Windows application that includes several method calls at startup will tend to have a faster load time if what is done?
    Answer: if the application is precompiled
  131. Question: Which property of a DataColumn object could you use to create a calculated value or aggregate column?
    Answer: Expression
  132. Question: Which base class should you inherit if you want to create custom trace listeners?
    Answer: TraceListener
  133. Question: When requesting code permissions
    which option indicates that the assembly should be denied a permission?
  134. Question: When does the BeginPrint event of a PrintDocument fire?
    Answer: when the Print method is called and before the first page of the document prints
  135. Question: Which unmanaged components must be installed if your application uses the SQL Server .NET Data Provider?
    Answer: Microsoft Data Access Components (MDAC) 2.6 or higher
  136. Question: What is the difference between a Debug build and a Release build of an application?
    Answer: A Debug build is compiled with full symbolic debug information and is not optimized
  137. Question: Which property of a menu item can you set to toggle on or off a check mark beside the menu item when the item is selected?
    Answer: Checked
  138. Question: What does a strong name for a strong-named assembly contain?
    Answer: the assembly's name
  139. Question: Which class implements the set of exceptions that relate to invalid implicit or explicit data type conversions?
    Answer: InvalidCastException
  140. Question: Which namespace represents the OLE DB .NET Data Provider?
    Answer: System.Data.OleDb
  141. Question: What is the difference between the Clone and Copy methods of a DataSet?
    Answer: Clone copies only the structure
  142. Question: Why would you use the predefined License Agreement dialog box?
    Answer: to prompt the user to accept or reject a license agreement during installation
  143. Question: Which statement can you use to explicitly raise an error?
    Answer: throw
  144. Question: What is a publisher policy file?
    Answer: A file
  145. Question: Which DataView property specifies a string indicating the sort order of the rows returned?
    Answer: Sort
  146. Question: When does theQueryPageSettings event of a PrintDocument fire?
    Answer: immediately before each PrintPage event
  147. Question: What is the file name extension for a merge module file?
    Answer: .msm
  148. Question: What would be the name of the configuration file for app1.exe?
    Answer: app1.exe.config
  149. Question: Which .NET Framework utility would you use to install aWindows Service application?
    Answer: Installutil.exe
  150. Question: Which property of a DataView allows you to easily sort the view based on the primary key column or columns of the underlying table?
    Answer: ApplyDefaultSort. For this property to apply the default sort
  151. Question: When writing XML from a DataSet using DataSet.WriteXml
    how can you specify the tag name of the root element of the XML file?
  152. Question: Can you call System.Configuration.ConfigurationSettings.AppSettings.Get() to read a setting from machine.config?
    Answer: Yes
  153. Question: When is the Select event of a menu item raised?
    Answer: when the menu item is highlighted
  154. Question: Which configuration file affects all .NET applications on a system?
    Answer: machine.config
  155. Question: Which utility is used to register or unregister .NET classes in theWindows Registry for use with COM?
    Answer: Regasm.exe (the Assembly Registration tool)
  156. Question: Which method of a control invalidates a specific region of the control and then causes a paint message to be sent to the control?
    Answer: Invalidate
  157. Question: Which utility is used during the setup of a deployment project to create the folder structure that your application will use when deployed?
    Answer: File System Editor
  158. Question: Which object redirects output to a previously specified event log?
    Answer: EventLogTraceListener
  159. Question: Can setting the Dock property of a control affect the size of the control at run time?
    Answer: Yes. Any docked edge of a control is resized when its container is resized.
  160. Question: Which FormBorderStyle values do not allow the user to resize the form?
    Answer: None and all of the Fixed styles
  161. Question: Which operator would you use to associate an event handler with an event?
    Answer: +=
  162. Question: Which tool generates X.509 certificates for testing purposes only?
    Answer: Makecert.exe (the Certification Creation tool)
  163. Question: Code access security policies can be defined at which four levels?
    Answer: enterprise
  164. Question: What is the term that refers to code that runs under the CLR (common language runtime)?
    Answer: managed code
  165. Question: At which point in the event life cycle of a control does the Validating event occur?
    Answer: immediately before the control is validated
  166. Question: Why might you implement the TraceSwitch class in your code?
    Answer: to provide conditional control of when or how tracing will occur
  167. Question: Which HTML tag is used to host aWindows Forms control in a web page?
  168. Question: What is the purpose of the Condition property for files that are added using the File System Editor?
    Answer: to indicate whether or not certain files should be installed on the target computer
  169. Question: What is the correct syntax to add a configuration setting with the key mykey and the value One to an section of a .config file?
  170. Question: What is the base class for classes containing event data?
    Answer: EventArgs
  171. Question: Which property of a menu item would you set to display a radio button beside the item when the item is selected?
    Answer: RadioCheck
  172. Question: What does theWindowsIdentity object returned by the GetAnonymous method represent?
    Answer: an anonymousWindows user
  173. Question: What is garbage collection?
    Answer: the process by which the CLR automatically reclaims unused memory
  174. Question: Which tool can you use to precompile an assembly into a native image?
    Answer: ngen.exe (Native Image Generator)
  175. Question: What is remoting?
    Answer: distributing objects across different process and machine boundaries
  176. Question: Which common ADO .NET class is a leaner alternative than the combination of a DataSet and DataAdapter for performing a simple forward read of data that is iterated only once?
    Answer: DataReader
  177. Question: Which DataSet method can you use to combine two DataSet objects?
    Answer: Merge
  178. Question: Which property of a check box must be set to True for any shortcut keys defined for the control to function?
    Answer: AutoCheck
  179. Question: Which type of code access security check is done in a method using objects and method calls?
    Answer: imperative
  180. Question: Which type of testing allows you to test individual components and fix bugs in them before they are integrated with the rest of the application?
    Answer: unit testing
  181. Question: What does the CodeAccessPermission.Demand method require?
    Answer: It requires that all callers higher in the call stack have the permission to access the resource. If these users have not been granted the permission
  182. Question: Which default event log records events specific to a particular user program?
    Answer: application
  183. Question: What does theQuickWatch dialog allow you to do?
    Answer: view variables and expressions or edit values
  184. Question: Which class does the .NET class library provide to represent a user during a custom logon procedure?
    Answer: GenericIdentity
  185. Question: For what reason would you use caspol.exe?
    Answer: to modify security policy for the machine policy level
  186. Question: What is a strong-named assembly?
    Answer: A strong-named assembly is an assembly that has been given a strong name that uniquely identifies the assembly.
  187. Question: Which value does the IsSubsetOf method return if the specified identities and roles are identical?
    Answer: True
  188. Question: Which form property defines which button will be clicked when the user presses the ESC key?
    Answer: CancelButton
  189. Question: When does the Control.HelpRequested event fire?
    Answer: when the application user requests help for a control by pressing the F1 key when the control has focus
  190. Question: Which debug window displays all variables currently in scope?
    Answer: Locals window
  191. Question: Which method would you use to return aWindowsIdentity object representing the currently logged onWindows user?
    Answer: GetCurrent
  192. Question: On which operating systems are Event Logs available?
    Answer: Windows NT
  193. Question: What are the three default event logs?
    Answer: system
  194. Question: Which tool is used to aid you in generating the necessary file type associations on the target computer for your application?
    Answer: the File Types Editor in the IDE
  195. Question: Which DataView property can you use to specify which rows should be included in the view based on the state of the rows?
    Answer: RowStateFilter
  196. Question: Instances of which class can be used to read tracing levels from the section of an application's configuration file?
    Answer: TraceSwitch
  197. Question: What is connection pooling?
    Answer: the process of creating connections to the database where the same user id and password is shared by multiple users
  198. Question: What is a Principal?
    Answer: an object that represents the identity and role of a user and acts on behalf of the user
  199. Question: Which method of a DataTable commits all pending changes?
    Answer: AcceptChanges
  200. Question: Which .NET Framework tool would you use to view the declarative permission demands made by an assembly?
    Answer: permview.exe
  201. Question: What does a .pdb file contain?
    Answer: debugging and project state information
  202. Question: What is a destructor?
    Answer: code that runs immediately before a class is removed from memory
  203. Question: Why would you use the CodeAccessPermission.Assert method?
    Answer: to specify that the calling code can access the resource identified by the current permission
  204. Question: Which object would you use to represent a custom control that contains multiple Windows Form controls?
    Answer: UserControl
  205. Question: Which property of a DataSet can you set to True to force constraint rules to apply when attempting to insert or update data?
    Answer: EnforceConstraints
  206. Question: What does the Debug Processes menu entry under the Tools menu do?
    Answer: It allows you to attach to a running process on the local computer to debug it in the Visual Studio .NET IDE.
  207. Question: To what does the term side-by-side execution refer?
    Answer: concurrently running multiple versions of the same assembly
  208. Question: Which block in a structured error handler is used to filter the exceptions?
    Answer: catch
  209. Question: Which form event fires as a form is being closed?
    Answer: Closing
  210. Question: Which three columns display in the Breakpoints window?
    Answer: Name
  211. Question: Which dialog box is used to create an inherited form?
    Answer: Inheritance Picker
  212. Question: What is a constructor?
    Answer: code that runs when an object is instantiated
  213. Question: What are the two steps involved in imperatively demanding specific code access security?
    Answer: 1. Create an instance of a permission object to represent the permissions being requested.2. Call the Demand() method of the permission object.
  214. Question: Which provider control would you use to create pop-up help that would display when the user pressed the F1 key?
    Answer: HelpProvider
  215. Question: Which operator would you use to disassociate an event handler from an event?
    Answer: -=
  216. Question: Which .NET namespace includes classes that make up the disconnected part of the ADO .NET architecture?
    Answer: System.Data
  217. Question: Which control property identifies the control in code?
    Answer: Name
  218. Question: What is the name of the machine-specific location that stores shared assemblies?
    Answer: Global Assembly Cache
  219. Question: Why would you include a single ampersand in the Text property of a control?
    Answer: to create an access key to use as a shortcut key
  220. Question: To which namespace does the Trace class belong?
    Answer: System.Diagnostics
  221. Question: Which method of the Trace class allows you to selectively output information followed by a line terminator based on a condition evaluating true or false?
    Answer: WriteLineIf
  222. Question: Which namespace represents the SQL Server .NET Data Provider?
    Answer: System.Data.SqlClient
  223. Question: Which collection object contains all the controls on a form or on a container control?
    Answer: ControlCollection
  224. Question: Which method of a SqlConnection object could you use to initiate a database transaction?
    Answer: SqlConnection.BeginTransaction
  225. Question: What is an XML schema?
    Answer: a description
  226. Question: Which operating systems currently supportWindows Installer files?
    Answer: all Microsoft operating systems starting withWindows 95
  227. Question: Which type of setup project allows you to create a cabinet file for download with legacy browsers?
    Answer: Cab Project
  228. Question: Which .NET Framework tool can you use to create a text file containing an assembly's content?
    Answer: ildasm.exe
  229. Question: Which class provides data to the PrintPage event?
    Answer: PrintPageEventArgs
  230. Question: What does the RequestMinimum security action provide?
    Answer: It requests a permission that must be granted for the assembly to execute.
  231. Question: Which DataSet method could you use to create a second DataSet containing only the changed records of the original DataSet?
    Answer: GetChanges
  232. Question: How do you deploy aWeb application to aWeb server?
    Answer: Create aWeb Setup project
  233. Question: Constituent controls in a base control can have which Modifier property values so that theWindows Form Designer can be used to size and move them in a derived control?
    Answer: public and protected
  234. Question: Which syntax would you use to create a destructor for the MyClass class?
    Answer: ~ MyClass() { // Include statements }
  235. Question: Which method of the DataTable class returns a DataTable to its original state?
    Answer: Reset
  236. Question: Must you always distribute a configuration file with a .NETWindows application?
    Answer: No
  237. Question: Which object can you use to read from or write toWindows event logs or custom event logs that you define?
    Answer: EventLog
  238. Question: Which Property Attribute will prevent a Public property of a custom control from appearing in the Property Browser at design time?
    Answer: [Browsable(False)]
  239. Question: What is required to digitally sign application code?
    Answer: a PKI method such as a digital certificate
  240. Question: Which property specifies the underlying DataTable for a DataView?
    Answer: DataView.Table
Card Set
C# programming Test Questions.txt
C# Test Questions