Esempio n. 1
0
 public static Byte ExtraeValorNumericoByteCelda(int valorCelda, string nombreCampo, GridViewDeleteEventArgs e, GridView gridview)
 {
     DataControlFieldCell cell = (DataControlFieldCell)gridview.Rows[e.RowIndex].Cells[valorCelda];
     BoundField field = (BoundField)cell.ContainingField;
     System.Collections.Specialized.OrderedDictionary dict = new System.Collections.Specialized.OrderedDictionary();
     field.ExtractValuesFromCell(dict, cell, DataControlRowState.Edit, true);
     return DataTypeCode.ConvertirAByte(dict[nombreCampo].ToString().Replace("$", "").Trim());
 }
Esempio n. 2
0
    }//string

    public static string ExtraeValorCelda(int valorCelda, string nombreCampo, GridViewDeleteEventArgs e, GridView gridview)
    {
        DataControlFieldCell cell = (DataControlFieldCell)gridview.Rows[e.RowIndex].Cells[valorCelda];
        BoundField field = (BoundField)cell.ContainingField;
        System.Collections.Specialized.OrderedDictionary dict = new System.Collections.Specialized.OrderedDictionary();
        field.ExtractValuesFromCell(dict, cell, DataControlRowState.Edit, true);

        if (dict[nombreCampo] == null)
            return string.Empty;
        else
            return dict[nombreCampo].ToString().Replace("$", "").Trim();

    }//string