Below is a code extract from an ASP.Net application.
The code basically reads data from the “name” field in
the “members” table and prints them onto the webpage.
Using the assumptions provided, fill in the 4 blanks below
so that the code will run correctly.
‘Assumptions:
‘conn_str is a variable that holds the connection string to
the database
‘Objects dbcomm and dbread are already declared earlier
dbcomm = New OleDbCommand("SELECT name FROM members",
conn_str)
dbread = dbcomm._______________
_____________________
response.write(_______________)
_____________________
dbread.Close()

Answer Posted / chauhan rakesh botad

dbcomm = New OleDbCommand("SELECT name FROM members",
conn_str)
dbread = dbcomm.ExecuteReader()
while(dbread.Read())
response.write(dbread.GetString(1)))
dbread.NextResult()
dbread.Close(

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How does asp page work?

739


What is the difference between custom web user control and a custom web server control?

713


What is the use of view state?

723


To display data in the combo box, prior to setting the Data Source, what kind of property on a Combo Box do you set with a column name?

815


Describe the .net base class library.

750


What are the different types of sessions in asp.net?

698


What is query string with example?

724


What are the uses of reflection?

791


When Cookies are expired in ASP.NET?

781


Define xmlvalidatingreader class.

826


Define secured sockets layer.

710


List of words of preprocessor in .net?

714


What is form method?

705


How many types of file extensions for razor views in ASP.Net MVC?

796


Why web api is better than wcf?

793