In each cell of my gridview combobox column, I have 2 items ("abc" and "xyz"). In the Excel spread sheet, I have 2 rows, but I am not getting the result when I paste those 2 row into telerik gridview, here are the scenario:
1. If first row is "abc" and second row is "xyz", result is ok,
2. If first row is "abc" and second row is "fgh" which "fgh" is not in any of the combobox items, when I paste into gridview, I get "abc" on both rows!
So it seems that when I paste a value that does not exist in the combobox, it simply pick the "prior" row data (which is valid) and "stuff" it in. Is there anyway to get "blank" when the value does not exist in the combobox, instead of this "fake wrong data" being stuff in?
The reason is that the person who pasted does not know that he just pasted a "dirty data" into the grid. But by making it "blank", the person can see quickly on the screen that there is a "blank" and thus need to pick a valid value.
I did try to find a way to "validate" the data with the copypaste event of the grid, but the problem is that it seems there is no "finditembytext / value" method like your ASP.NET datagrid. I was thinking that if during the "pasting" event, I can see if the "copy" value exist in the combobx column (datasource) and if does not exist, 'cancel" the operation. But again, I don't know what is the "method" to call within the gridview comboboxcolumn object.
thx!
1. If first row is "abc" and second row is "xyz", result is ok,
2. If first row is "abc" and second row is "fgh" which "fgh" is not in any of the combobox items, when I paste into gridview, I get "abc" on both rows!
So it seems that when I paste a value that does not exist in the combobox, it simply pick the "prior" row data (which is valid) and "stuff" it in. Is there anyway to get "blank" when the value does not exist in the combobox, instead of this "fake wrong data" being stuff in?
The reason is that the person who pasted does not know that he just pasted a "dirty data" into the grid. But by making it "blank", the person can see quickly on the screen that there is a "blank" and thus need to pick a valid value.
I did try to find a way to "validate" the data with the copypaste event of the grid, but the problem is that it seems there is no "finditembytext / value" method like your ASP.NET datagrid. I was thinking that if during the "pasting" event, I can see if the "copy" value exist in the combobx column (datasource) and if does not exist, 'cancel" the operation. But again, I don't know what is the "method" to call within the gridview comboboxcolumn object.
thx!