/// <summary> /// Get product details of selected ARC /// </summary> /// <param name="arcId"></param> private void BindProducts(int arcId) { db = new LinqToSqlDataContext(); var ProductData = db.USP_GetProductsByArc(arcId); // call sp gvProducts.DataSource = ProductData; gvProducts.DataBind(); if (gvProducts.Rows.Count == 0) { string script = "alertify.alert('" + ltrNoMap.Text + "');"; ScriptManager.RegisterStartupScript(this.Page, this.GetType(), "alert", script, true); } }