Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: ASP.NET
Can anyone give solution?
 
give stored procedure for shopping cart details?here i don't know how to do?
protected void btncart_Click(object sender, EventArgs e)
    {
        if (con.State == ConnectionState.Closed)
        {
            con.Open();
        }
        SqlCommand cmd = new SqlCommand("addcart1", con);
        cmd.CommandType = CommandType.StoredProcedure;
        cmd.Parameters.AddWithValue("@mastreid",OleDbType.VarChar,50);
        cmd.Parameters.AddWithValue("@usersession");
        cmd.Parameters.AddWithValue("@pro_id");
        cmd.Parameters.AddWithValue("@pro_name");
        cmd.Parameters.AddWithValue("@price");
        cmd.Parameters.AddWithValue("@quantity");
        cmd.Parameters.AddWithValue("@type");
        cmd.Parameters.AddWithValue("@pro_img");
        cmd.ExecuteNonQuery();
 
    }
Posted 23-Nov-11 21:49pm
Edited 23-Nov-11 22:07pm
thatraja242.6K
v3
Comments
Anuja Pawar Indore at 24-Nov-11 2:54am
   
Not a question.
OriginalGriff at 24-Nov-11 3:00am
   
We would need more information that that. What exactly are you trying to do? What part of that is giving you difficulties?
Use the "Improve question" widget to edit your question and provide better information.
mark merrens at 24-Nov-11 3:08am
   
Are you unable to create a stored procedure? What have you tried for yourself?
Prince Antony G at 24-Nov-11 3:08am
   
Give more explaniation.
what is ur requirement..
sathiyak at 24-Nov-11 3:12am
   
here i have create the stored procedure but in the add cart button i use this sp but for addcart i have no forms.....pls can anyone understand?

1 solution

Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 285
1 DamithSL 265
2 CPallini 195
3 Maciej Los 175
4 George Jonsson 170
0 OriginalGriff 5,415
1 DamithSL 4,422
2 Maciej Los 3,820
3 Kornfeld Eliyahu Peter 3,470
4 Sergey Alexandrovich Kryukov 2,911


Advertise | Privacy | Mobile
Web02 | 2.8.141216.1 | Last Updated 24 Nov 2011
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100