Hi,
How to retrieve below all data from Web Page in Asp.net. Please find attachment of database.
I want to display with given query---
select * from createuser where acount='w34'
Kindly assist on it
Loading
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Munesh SharmaPosted Apr 25, 2014, 7:51 AM
http://www.aspdotnet-suresh.com/2011/01/how-to-insert-images-into-database-and.html
Hemant KumarPosted Apr 25, 2014, 7:21 AM
using (SqlConnection conn = ...)
{
conn.Open();
using (SqlCommand cmd = new SqlCommand("SELECT Picture FROM
using (SqlDataReader reader = cmd.ExecuteReader())
{
if (reader.Read())
{
byte[] picData= reader["Picture"] as byte[] ?? null;
if (picData!= null)
{
using (MemoryStream ms = new MemoryStream(picData))
{
// Load the image from the memory stream. How you do it depends
// on whether you're using Windows Forms or WPF.
// For Windows Forms you could write:
System.Drawing.Bitmap bmp = new System.Drawing.Bitmap(ms);
}
}
}
}
}
If you have any doubts refer this example http://www.aspsnippets.com/Articles/Retrieve-images-using-a-file-path-stored-in-database-in-ASPNet.aspx