void MostrarDatos() { int n_row = 0; string c_dato = ""; double n_valor = 0; double n_horini = 0; double n_horfin = 0; LblApeNom.Text = c_apenomtra; LblNumDoc.Text = c_numdoc; LblFchTra.Text = c_fchtra; FgLisPer.Rows.Count = 2; if (dtTareas.Rows.Count != 0) { for (n_row = 0; n_row <= dtTareas.Rows.Count - 1; n_row++) { FgLisPer.Rows.Count = FgLisPer.Rows.Count + 1; c_dato = dtTareas.Rows[n_row]["c_des"].ToString(); FgLisPer.SetData(FgLisPer.Rows.Count - 1, 1, c_dato); n_valor = Convert.ToDouble(funFunciones.NulosN(dtTareas.Rows[n_row]["n_can"])); FgLisPer.SetData(FgLisPer.Rows.Count - 1, 2, n_valor.ToString("0.00")); c_dato = dtTareas.Rows[n_row]["c_horini"].ToString(); FgLisPer.SetData(FgLisPer.Rows.Count - 1, 3, c_dato); c_dato = dtTareas.Rows[n_row]["c_horter"].ToString(); FgLisPer.SetData(FgLisPer.Rows.Count - 1, 4, c_dato); n_horini = funCon.HoraEnDecimal(dtTareas.Rows[n_row]["c_horini"].ToString() + ":00"); n_horfin = funCon.HoraEnDecimal(dtTareas.Rows[n_row]["c_horter"].ToString() + ":00"); n_valor = n_horfin - n_horini; c_dato = funCon.DecimalEnHoras(n_valor); FgLisPer.SetData(FgLisPer.Rows.Count - 1, 5, c_dato); n_valor = Convert.ToDouble(funFunciones.NulosN(dtTareas.Rows[n_row]["n_pretar"])); FgLisPer.SetData(FgLisPer.Rows.Count - 1, 6, n_valor); n_valor = Convert.ToDouble(funFunciones.NulosN(dtTareas.Rows[n_row]["n_imptot"])); FgLisPer.SetData(FgLisPer.Rows.Count - 1, 7, n_valor); } } //LblTot1.Text = funFlex.FlexSumarCol(FgLisPer, 6, 2, FgLisPer.Rows.Count - 1).ToString("0.00"); LblTot2.Text = funFlex.FlexSumarCol(FgLisPer, 7, 2, FgLisPer.Rows.Count - 1).ToString("0.00"); }