You are on page 1of 5

1. You want to pass the user name entered in the login form to another Web page .

Which of the following parameters in the parameterized queries helps you to archive this task ? Form Cookie Control QueryString 2. Which of the following codes retrieves the number of items in the control? Response.Write(this.objLstCountries.AllFields[0].Title); Response.Write(objLstCountries.SelectedIndex); int count = objlstCountries.ItemCount; if(objlstCountries.SelectListItem(o,false)) { Response.Write("Selected"); } 3. Which of the following codes correctly removes the item named StudentsDataTable from the cache ? Cache.Delete("StudentsDataTable"); Cache.Remove("StudentsDataTable"); Caching.Remove("StudentDataTable"); Caching.Clear("StudentsDataTable"); 4. The ......element in the Web.config file stores the connection string. connectionData connectionStrings connectionType connection 5. Which approach specifies the location of output cache using the Location attribute of @OutputCache directive? parameterized approach Substitution approach Declarative approach Programmatic approach 6. Items stored on the cache are removed using the....... method. Cache.Remove() Cache.Delete() Cache.Erase() Cache.Drop(0 7. Which of the following statements about untyped datasets are true? Untyped datasets require you to create the schema for the dataset. It is not possible to work with data from a database using untyped datasets. An object is created when you create an untyped dataset. The NewRow() method is used to add rows into an untypted DataTable that is part of an untyped dataset. 8. How many instances of the Cache class representing a Cache object Web application? One Two Depends on the number of pages in the application Zero 9. A user control is cached by including an ....... directive in the .ascx file of control? @Cache @OutputCache

@Register @Control 10. Which of the following statement correctly describe the usage of the XmlReader.ReadString() method ? It retrieves the XML representation of the data in a DataSet object as a string. It returns the XML content as an XmlReader object. It reads content and optionally schema from an XML stream or file into a DataSet object. It reads the content of an element or text node as a string. 11. Which of the following techniques can be used to add parameters queries as design time? Using Configure Data Source dialog box Using markup elements such as <SelectParameters> and <DelectParameters> . Only 1 Only 2 1 and 2 12. You want to add SQL dependency for a connection string ... database should be polled every 7 minutes. Which one.....you to accomplish this? A. <Caching> <sqlCacheDependency enabled ="true" pollTime="420000"> (pollTime tnh bng millisecond tng ng 60 giy l 60000 mili giy) <databases> B. <Caching> <sqlCacheDependency enabled ="true" pollTime="7"> <databases> C. <Caching> <sqlCacheDependency enabled ="true" pollTime="42000"> <databases name="Eudora" connectionStringName="Eudora"/ > D. <Caching> <sqlCacheDependency enabled ="true" pollTime="420"> <databases> 13. Which property of data source controls retrieves the time in seconds for which the control caches the data ? EnableCaching CacheExpirationPolicy SqlCacheDependency CacheDuration 14. Which of the following Boolean properties in a SiteMapDataSource control sets or gets a value to indicate whether the start node is displayed? StartFromCurrentNode ShowStartingNode StartingNodeUrl ShowStartNode 15. .................. represents a query or a command that is to be executed by a data source Connection Command DataSet DataApdater 16. ......... is a mobile control that is exclusively designed for mobile data access and can display a list as well as a detail view. SelectionList

List DropDownList ObjectList 17. ....... is a group of class that enables the developers to connect to RDBMS ADO.NET AOD.NET ASP OAD.NET 18. Which of the following codes retrieves the connection string from.... String conString = ConfigurationManager.ConnectionStrings["TestConnection"]; String conString = WebConfigurationManager.ConnectionStrings["TestConnection"].ToString(); String conString = Config.ConnectionStrings["TestConnection"].ToString(); String conString = WebConfiguration.Connection["TestConnection"].ToString(); 19. Which of the following dataset class represents the data type of Column of DataTable ? DataRow DataColumn DataTable DataColumnCollection 20. Which of the following classes stores the frequently used application for a Web application? System.Web.Cache System.Web.Caching.Cache System.Web.Caching System.Cache 21. Which of the following are the new features provided in ASP.NET 2.0 ? Control that access data from the back-end database. Control that can display data in various formats. Direct connections can be established as a local file to an SQL Express database. 12 13 23 All of the above. 22. Which property of the GridView control regarding paging functionality indicates whether the paging buttons are displayed? PagerSettings.PreviousPageText PagerSettings.Visible PagerSettings.Mode PageIndex 23. ...... is a process by which the data in the control belonging to the UI have a direct link to the data in the database. Static binding Dynamic binding Data binding Data Linking 24. The ....... method of a SqlCommand object returns an instance of SqlDataReader class . Execute() ExecuteReader() Create() Init()

25. Which of the following are valid events of DataList control ? SelectedIndexChanged DeletingCommand UpdateCommand CancellingCommand EditCommand 26. Which event is raised when each item in a mobile List control is being data bound? ItemDataBound DataItemBind ListItem ItemDataBind 27. Which property of @OutputCache directive creates a new version of a page if the request for the same page comes from a different browser ? VaryByHeader VaryByParam VaryByVersion VaryByCustom 28. The.....object is used to fetch and update the data from the database. DataSet Data adapter DataTable DataColumn 29. The.... data source control enables you to work with ASP.NET site navigation through XMLbased site maps. SqlDataSource XmlDataSource SiteMapDataSource NavigationDataSource 30. Which of the following represents the correct directive to be used when working with data sources associated with an OracleConnection ? using System.Data.Oracle; using System.Data.OracleDb; using System.Data.OracleClient; using System.Data.Odbc; 31. The..... Datasets require the user to hard-code the schema of the dataset. untyped typed row column 32. Which of the following codes correctly clears the content of the dataset and fills it with rows of data ? A. dsetFootwear.Tables["Footwear"].clrscr(); sdaFootwear.doFill(dsetFootwear,"Footwear"); B. dsetFootwear.Tables["Footwear"].ClearAll(); sdaFootwear.FillDataset(dsetFootwear,"Footwear"); C.dsetFootwear.Tables["Footwear"].FlushAll(); sdaFootwear.FillSet(dsetFootwear,"Footwear"); D. dsetFootwear.Tables["Footwear"].Clear();

sdaFootwear.Fill(dsetFootwear,"Footwear"); 33. Which one of the following statement stating the characteristics of OleDbDataReader class is true ? It reads a stream of rows from a SQL Server database. It reads a stream of rows from a data source that is associated with an OleDbConnection. It reads a stream of rows from a data source associated with an OdbcConnection. It reads a stream of rows from Oracle data sources. 34. Which of the following classes generates dynamic customized views of your data which you can then display and manipulate? DataView GridView DataList DetailsView 35. Which of the following are the ways to add items to a cache? Using key/value pairs Using Cache.Insert() method Using Cache.Add() method 13 23 12 All of the above 36. The ...... property specifies whether the display of records will be repeated horizontally or vertically. RepeatDirection RepeatLayout RepeatColumns RepeatList 37. Which of the following Web server control presents the data in a list? DataControl DataList GridView DataBind 38. Following is a series of steps to bind a data source control to a data-bound control on a Web form . Bind the data source control to a data-bound control. Add the data source control to the Web form. Configure the properties of the data source control. Select the kind of data source control. Select the data provider. 45231 12345 24531 43125 39. Which of the following codes will allow you to fill an untyped dataset named dsetEmplyees with the data from the Employees table in a SQL Server 2005 database? SqlConnection sqlconPubs = new SqlConnection("Data Source=10.2.1.51;Initial Catalog=pubs;User ID =sa;Password=playware"); SqlDataAdapter sdaEmployee = new SqlDataAdapter("select * from Employees",sqlconPubs); DataSet dsetEmployee = new DataSet(); sdaEmployee.Fill(dsetEmployee,"Employees");

You might also like