foreach (DataListItem item in DataList1.Items)
{
// Get the checkbox control that contain the user selection.
CheckBox cbSelProducts = (CheckBox)item.FindControl("cbSelProduct");
if (cbSelProducts != null && cbSelProducts.Checked)
{
// Label lblProductName = (Label)row.FindControl("lblProductName");
/// Get the product id of the selected product
string TitleId = "";
Label id = (Label)item.FindControl("lblCatId");
DataSet ds = obj.GetTitleId(id.Text);
if (ds.Tables[0].Rows.Count > 0)
{
TitleId = ds.Tables[0].Rows[0]["TitleId"].ToString();
}
insert query write here
}
No comments:
Post a Comment