datagridview - DataGridViewCell with custom format fails to parse in C# -
i have datagridview different columns. 1 of these columns holds number (short) represents time. have set custom format "00:00" in cell style. if number 1800, displayed (formatted) value 18:00, if value 50, displayed value 00:50.
this works fine long cell's "parseformattedvalue" method not used. method fails format exception if pass formatted value "18:00", example. doesn't work if cell style's format-property holds correct format string?
accordingly method documentation:
    //   system.formatexception:     //     system.windows.forms.datagridviewcell.formattedvaluetype property value     //     null.-or-the system.windows.forms.datagridviewcell.valuetype property     //     value null.-or-formattedvalue cannot converted. which parameters passing?
Comments
Post a Comment