shopping cart

Results 1 to 2 of 2

Thread: shopping cart

  1. #1
    Join Date
    Dec 1969

    Default shopping cart

    Hi <BR>I am trying to develop a shopping in .net. I am using datalist to <BR>display the cart and the item number and its quantity are stored in <BR>the ListDictionary. The datasource for the DataList is the <BR>ListDictionary.I was wondering as to how I can update the quantity of <BR>the shopping cart. I am using a textbox for inputing the value for <BR>quantity.Here is the code:<BR><BR>aspx code<BR>&#060;asp:TextBox ID="text1" MaxLength=3 Width=35 TextMode=SingleLine <BR>Text=&#039;&#060;%#container.dataitem.value%&# 062;&#039; Runat=server&#062;&#060;/asp:TextBox&#062;<BR><BR><BR>&#060;asp:LinkButton text="update" Runat="server" CommandName="update" <BR>CommandArgument="&#060; y%&#062;"&#062;&#060;/asp:LinkButton&#062;<BR><BR><BR>vb code<BR>Sub rpt1_UpdateCommand(ByVal s As Object, ByVal e As <BR>System.Web.UI.WebControls.DataListCommandEvent Args) Handles <BR>rpt1.UpdateCommand<BR>Dim qty As TextBox<BR>Dim i As String<BR>Dim s1 As String<BR>i = e.Item.ItemIndex<BR>s1 = e.CommandArgument<BR>qty = CType(FindControl(e.Item.ItemIndex), TextBox)<BR>dictcart.Item(e.CommandArgument) = qty.Text<BR>rpt1.EditItemIndex = -1<BR><BR>ShowCart()<BR><BR>End Sub<BR><BR>The code should read the value of the textbox which it is not .Can <BR>some one please tell me where am i going wrong???<BR><BR>Thank you<BR><BR>

  2. #2
    Join Date
    Dec 1969

    Default RE: shopping cart

    While I do not plan to answer your question, I would recommend looking at the ASP.NET Starter Kits that could possibly shave off a considerable amount of your development time.<BR><BR><BR><BR>(Commerce starter kit)<BR><BR>Hopefully, you can find someone else to answer your question.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts