Using XML and ADO.Net in ASP.Net pagesThe important namespaces that you have to import for working with XML and ADO.Net in ASP.Net pages are System.Data, System.Data.OleDb or System.Data.SqlClient, System.Xml, and System.Xml.Xsl To work with the ADO.Net you have to first open a connection object, for example with an OleDbConnection. The connection string can be stored in a string variable and this variable can be passed to the connection object, to open a connection with the database. Then create a query string variable to hold the query and pass the connection object and the query string to the DataAdapter object to create a DataAdapter. Now create a DataSet object and fill the DataAdapter object with the DataSet. Now you can close the connection. Now you can work with the dataset object to display the data in the asp.net page.It is possible to create an xml document from the data that is got in the dataset and transform that document with the help of the xsl style sheet.
|
|
|||
|
||||
“Amazon and the Amazon logo are trademarks of Amazon.com, Inc. or its affiliates.”
Copyright - © 2004 - 2019 - All Rights Reserved.