Sugerir traducción
 
Otros han sugerido:

progress indicator
No hay más sugerencias.
Evaluar y enviar comentarios
Contraer todo/Expandir todo Contraer todo
Ver contenido:  en paraleloVer contenido: en paralelo
.NET Framework Class Library
DataGridViewCell..::.ParseFormattedValue Method

Converts a value formatted for display to an actual cell value.

Namespace:  System.Windows.Forms
Assembly:  System.Windows.Forms (in System.Windows.Forms.dll)
Visual Basic
Public Overridable Function ParseFormattedValue ( _
    formattedValue As Object, _
    cellStyle As DataGridViewCellStyle, _
    formattedValueTypeConverter As TypeConverter, _
    valueTypeConverter As TypeConverter _
) As Object
C#
public virtual Object ParseFormattedValue(
    Object formattedValue,
    DataGridViewCellStyle cellStyle,
    TypeConverter formattedValueTypeConverter,
    TypeConverter valueTypeConverter
)
Visual C++
public:
virtual Object^ ParseFormattedValue(
    Object^ formattedValue, 
    DataGridViewCellStyle^ cellStyle, 
    TypeConverter^ formattedValueTypeConverter, 
    TypeConverter^ valueTypeConverter
)
F#
abstract ParseFormattedValue : 
        formattedValue:Object * 
        cellStyle:DataGridViewCellStyle * 
        formattedValueTypeConverter:TypeConverter * 
        valueTypeConverter:TypeConverter -> Object 
override ParseFormattedValue : 
        formattedValue:Object * 
        cellStyle:DataGridViewCellStyle * 
        formattedValueTypeConverter:TypeConverter * 
        valueTypeConverter:TypeConverter -> Object 

Parameters

formattedValue
Type: System..::.Object
The display value of the cell.
cellStyle
Type: System.Windows.Forms..::.DataGridViewCellStyle
The DataGridViewCellStyle in effect for the cell.
formattedValueTypeConverter
Type: System.ComponentModel..::.TypeConverter
A TypeConverter for the display value type, or nullNothingnullptra null reference (Nothing in Visual Basic) to use the default converter.
valueTypeConverter
Type: System.ComponentModel..::.TypeConverter
A TypeConverter for the cell value type, or nullNothingnullptra null reference (Nothing in Visual Basic) to use the default converter.

Return Value

Type: System..::.Object
The cell value.
ExceptionCondition
ArgumentNullException

cellStyle is nullNothingnullptra null reference (Nothing in Visual Basic).

FormatException

The FormattedValueType property value is nullNothingnullptra null reference (Nothing in Visual Basic).

-or-

The ValueType property value is nullNothingnullptra null reference (Nothing in Visual Basic).

-or-

formattedValue cannot be converted.

ArgumentException

formattedValue is nullNothingnullptra null reference (Nothing in Visual Basic).

-or-

The type of formattedValue does not match the type indicated by the FormattedValueType property.

When the user edits a cell value and commits the change, the DataGridView control calls this method to convert the displayed value from the FormattedValueType to the ValueType. The control then sets the underlying cell value or data source value to the converted value.

The default implementation of this method parses the formattedValue parameter using the NullValue, DataSourceNullValue, and FormatProvider properties of the cell style indicated by the cellStyle parameter.

If formattedValue is equal to NullValue, this method returns the value of the DataSourceNullValue property or nullNothingnullptra null reference (Nothing in Visual Basic) if DataSourceNullValue is DBNull..::.Value and the cell ValueType is a reference type.

If formattedValue is not equal to NullValue, this method parses formattedValue using the FormatProvider property and the specified or default converters.

If the cell ValueType is nullable, this method wraps the return value as a Nullable<(Of <(T>)>) type.

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role not supported), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Biblioteca de clases de .NET Framework
DataGridViewCell..::.ParseFormattedValue (Método)

Convierte un valor con formato de presentación en un valor de celda real.

Espacio de nombres:  System.Windows.Forms
Ensamblado:  System.Windows.Forms (en System.Windows.Forms.dll)
Visual Basic
Public Overridable Function ParseFormattedValue ( _
    formattedValue As Object, _
    cellStyle As DataGridViewCellStyle, _
    formattedValueTypeConverter As TypeConverter, _
    valueTypeConverter As TypeConverter _
) As Object
C#
public virtual Object ParseFormattedValue(
    Object formattedValue,
    DataGridViewCellStyle cellStyle,
    TypeConverter formattedValueTypeConverter,
    TypeConverter valueTypeConverter
)
Visual C++
public:
virtual Object^ ParseFormattedValue(
    Object^ formattedValue, 
    DataGridViewCellStyle^ cellStyle, 
    TypeConverter^ formattedValueTypeConverter, 
    TypeConverter^ valueTypeConverter
)
F#
abstract ParseFormattedValue : 
        formattedValue:Object * 
        cellStyle:DataGridViewCellStyle * 
        formattedValueTypeConverter:TypeConverter * 
        valueTypeConverter:TypeConverter -> Object 
override ParseFormattedValue : 
        formattedValue:Object * 
        cellStyle:DataGridViewCellStyle * 
        formattedValueTypeConverter:TypeConverter * 
        valueTypeConverter:TypeConverter -> Object 

Parámetros

formattedValue
Tipo: System..::.Object
El valor de presentación de la celda.
cellStyle
Tipo: System.Windows.Forms..::.DataGridViewCellStyle
DataGridViewCellStyle en vigor para la celda.
formattedValueTypeConverter
Tipo: System.ComponentModel..::.TypeConverter
TypeConverter para el tipo de valor de presentación o nullNothingnullptrreferencia null (Nothing en Visual Basic) para utilizar el convertidor predeterminado.
valueTypeConverter
Tipo: System.ComponentModel..::.TypeConverter
TypeConverter para el tipo de valor de celda o nullNothingnullptrreferencia null (Nothing en Visual Basic) para utilizar el convertidor predeterminado.

Valor devuelto

Tipo: System..::.Object
El valor de la celda.
ExcepciónCondición
ArgumentNullException

El valor de cellStyle es nullNothingnullptrreferencia null (Nothing en Visual Basic).

FormatException

El valor de la propiedad FormattedValueType es nullNothingnullptrreferencia null (Nothing en Visual Basic).

O bien

El valor de la propiedad ValueType es nullNothingnullptrreferencia null (Nothing en Visual Basic).

O bien

No se puede convertir formattedValue.

ArgumentException

formattedValue es nullNothingnullptrreferencia null (Nothing en Visual Basic).

O bien

El tipo de formattedValue no coincide con el tipo indicado por la propiedad FormattedValueType.

Cuando el usuario edita un valor de celda y confirma el cambio, el control DataGridView llama a este método para convertir el valor presentado de FormattedValueType a ValueType. A continuación, el control establece el valor de la celda subyacente o del origen de datos en el valor convertido.

La implementación predeterminada de este método analiza el parámetro formattedValue utilizando las propiedades NullValue, DataSourceNullValue y FormatProvider del estilo de celda que indica el parámetro cellStyle.

Si formattedValue es igual a NullValue, este método devuelve el valor de la propiedad DataSourceNullValue o nullNothingnullptrreferencia null (Nothing en Visual Basic) si DataSourceNullValue es DBNull..::.Value y la propiedad ValueType de la celda es un tipo de referencia.

Si formattedValue no es igual a NullValue, este método analiza formattedValue mediante la propiedad FormatProvider y los convertidores especificados o predeterminados.

Si la celda ValueType acepta valores NULL, este método ajusta el valor devuelto como tipo Nullable<(Of <(T>)>).

.NET Framework

Compatible con: 4, 3.5, 3.0, 2.0

.NET Framework Client Profile

Compatible con: 4, 3.5 SP1

Windows 7, Windows Vista SP1 o posterior, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (no se admite Server Core), Windows Server 2008 R2 (se admite Server Core con SP1 o posterior), Windows Server 2003 SP2

.NET Framework no admite todas las versiones de todas las plataformas. Para obtener una lista de las versiones compatibles, vea Requisitos de sistema de .NET Framework.
Contenido de la comunidad   ¿Qué es Community Content?
Agregar contenido nuevo RSS  Anotaciones
Processing
© 2012 Microsoft. Reservados todos los derechos. Términos de uso | Marcas Registradas | Privacidad
Page view tracker