Last post Feb 21, 2017 06:03 AM by Eric Du
Feb 20, 2017 08:13 AM|Emanuel Pirovano Arpa|LINK
i'm doing a web application in asp.net , connect to my sql ( server management ... ) , how can i print the output of a SELECT ?
Let me explain, i'm doing a RESEARCH function, and i write the SELECT command inside my app, but i don't understand how to see the result.
Someone can help me ?
Feb 20, 2017 08:37 AM|PatriceSc|LINK
For the UI part you two programming model: Web Forms and MVC. See
https://www.asp.net/learn. Ultimately the principle is that your server side page will generate HTML markup which is then sent back to the browser to show data.
Feb 20, 2017 08:53 AM|Emanuel Pirovano Arpa|LINK
Can you explain me ?
Feb 20, 2017 08:58 AM|Khuram.Shahzad|LINK
Feb 20, 2017 10:15 AM|Emanuel Pirovano Arpa|LINK
I cant find a answer to my question ....
Feb 20, 2017 10:37 AM|PatriceSc|LINK
It seems you already have some data retrievel code. Are you using Entity Framework or ADO.NET ? Assuming MVC and ADO.NET DataTables try
http://stackoverflow.com/questions/2243898/displaying-standard-datatables-in-mvc (which might explain why you don't find something, EF is used much more often than ADO.NET)
Else it's easier to help in a forum if you try something and ask about a particular problem rather for something general that is best solved by studying available tutorials.
Feb 21, 2017 06:03 AM|Eric Du|LINK
Hi Emanuel Pirovano Arpa,
According to your description, as far as I know, you want to retrieve data from database, then display it in the page. I think you need add some data control in the page, then bind the retrieved data to the control. Here are two samples about bind data
to ListView or GridView.
Retrieve (Get) data from SQL Server database and display in ASP.Net GridView using C# and VB.Net:
Display (Show) data in ListView from database in ASP.Net using C# and VB.Net: