I am using the following code to programatically paste content from Excel into the RadGridView:
When the excel content contains no formatting, the paste operation works perfectly (ex - "123"). However, when excel content contains formatted text (ex - "$123.00), the values are not pasted.
Example column definition:
...where InvoicedAccountsPayable is defined as:
I'm guessing the pasted value is not able to be parsed into a string. Is there a solution short of redefining InvoicedAccountsPayable as a string?
Thanks,
Brian
var pasteCommand = RadGridViewCommands.Paste as RoutedUICommand;
pasteCommand.Execute(
null, this.radGridView);
When the excel content contains no formatting, the paste operation works perfectly (ex - "123"). However, when excel content contains formatted text (ex - "$123.00), the values are not pasted.
Example column definition:
<
telerik:GridViewDataColumn
DataMemberBinding="{Binding InvoicedAccountsPayable, Mode=TwoWay}"
DataFormatString="{}{0:$#,##0.00;($#,##0.00)}"/>
...where InvoicedAccountsPayable is defined as:
public
decimal? InvoicedAccountsPayable { get; set; }
I'm guessing the pasted value is not able to be parsed into a string. Is there a solution short of redefining InvoicedAccountsPayable as a string?
Thanks,
Brian