I need help on how to insert product data (car) name ,make ,model , year , etc plus front image, side image , back image and inside image directly to the SQL server database and show only one picture with few info to the gridview or repaeter with only one image displaying.
Whan a user click to view more image or more product info , then a new form pops up or a user can be directed to a new page with all the whole informations and all the images now displaying for that particuler item the user clicks.
Please help

Pankaj PandeyRank #642 · 3.7K reputationPosted May 10, 2013, 12:51 AM EDT
show short info in grid view and put a hyprelink button bind with row id.
wher user clicks on that m for show full detail, make a querystring based page ,hyperlink create a url with id(eg abc.aspx?id=23)
get this id and show all detail on basis of id.
thanks
Riddhi ValechaRank #794 · 2.9K reputationPosted May 10, 2013, 4:56 AM EDT
I am giving you the methods of Insert and Display-
--------
INSERT-
------------
string s ="insert into products(column1, column2, column3,column4)values('"+value1+"','"+value2+"','"+value3+"','"+value4+"')";
SQLConnection con = new SQLConnection(@"connectionstring");
SQLCommand cmd = new SQLCommand(s,con);
cmd.ExecuteNonQuery();
------------------------------------
SELECT AND DISPLAY DATA
-------------------
string s1="select * from products where column1='"+value1+"'"; //This will fetch one entire row.
SQLConnection con = new SQLConnection(@"connectionstring");
SQLCommand cmd = new SQLCommand(s,con);
SQLDataAdapter adp = new SQLDataAdapter();
adp.SelectComman = cmd;
DataTable table = new DataTable();
adp.fill(table);
foreach(datarow dr in table)
{
textbox1.text = dr["column1"].ToString();
//Keep adding all the columns in this manner.
}
---------------
Do mark this as correct answer if this logic works for you.
Riddhi ValechaRank #794 · 2.9K reputationPosted May 10, 2013, 4:59 AM EDT
Querystring is very traditional way of passing values between webpages.
From the URL, any IT person can get the value of the columns in database.
If possible, use other wayss-like Session; Properties; etc.