Sequence to connect and retrieve data from database useig
dataset ?
Answer Posted / ashokdahiya
We r talking about vb.net not c# codding
system.data
system.data.sqlclient
dim con,s as string
con="Server=servername;database=name;uid=sa;pwd=;"
s="Select * from tablename"
dim ad as new sqldataadapter(s,con)
dim ds as dataset
ad.fill(ds)
dim dv as dataview= new dataview(ds.tables("tablename"))
dv.sort="Name desc"
listbox.datasource=ds
listbox.displayMember="Name"&"Age"&"sex"...
it will work fine thanx!
Is This Answer Correct ? | 2 Yes | 7 No |
Post New Answer View All Answers
How will you differentiate between ADO (ActiveX Data Object) and RDO (Remote Data Objects)?
What is untyped dataset?
Which one of the following objects is a high-level abstraction of the connection and command objects in ado.net?
Is ado.net an orm?
What is a serialized object?
How can we load multiple tables in a dataset?
How would you connect to a database by using .NET?
What is connection in ado.net?
Explain how to create dynamic gridview?
What are the various methods provided by the DataSet object to generate XML?
What is the role of clr?
What is ado.net object model?
Which provider is used to connect ms access, oracle, etc…?
Explain advantages of ado.net?
What is ole used for?