private void FgPro_CellButtonClick(object sender, C1.Win.C1FlexGrid.RowColEventArgs e) { if (FgPro.Col == 1) { DataTable dtResult = new DataTable(); string c_dato = ""; objItems.mysConec = mysConec; dtResult = objItems.BuscarItem("", "n_id", dtPro, 0); if (dtResult != null) { if (dtResult.Rows.Count != 0) { c_dato = dtResult.Rows[0]["c_despro"].ToString(); FgPro.SetData(FgPro.Row, 1, c_dato); c_dato = dtResult.Rows[0]["n_id"].ToString(); FgPro.SetData(FgPro.Row, 2, c_dato); if (funFunciones.NulosC(FgPro.GetData(FgPro.Rows.Count - 1, 1)) != "") { FgPro.Rows.Count = FgPro.Rows.Count + 1; } } } } }
private void FgPro_CellButtonClick(object sender, C1.Win.C1FlexGrid.RowColEventArgs e) { if (FgPro.Col == 1) { DataTable dtResult = new DataTable(); string c_dato = ""; objPro.mysConec = mysConec; dtResult = objPro.BuscarCliPro(dtProv, 1, "n_id", ""); if (dtResult != null) { if (dtResult.Rows.Count != 0) { c_dato = dtResult.Rows[0]["c_nombre"].ToString(); FgPro.SetData(FgPro.Row, 1, c_dato); c_dato = dtResult.Rows[0]["n_id"].ToString(); FgPro.SetData(FgPro.Row, 2, c_dato); FgPro.Rows.Count = FgPro.Rows.Count + 1; } } } }