This is a migrated thread and some comments may be shown as answers.

How to mark gridview column support keyboard

9 Answers 60 Views
GridView
This is a migrated thread and some comments may be shown as answers.
Ning
Top achievements
Rank 1
Ning asked on 12 Jun 2017, 07:05 AM

Dear Admin

I just have a RadGridView with two columns, and I have already set these column read-only to be 'True' , users are not allowed to do any change for these two columns' value. But if users would like to copy value in these two columns, how to implement such request? I tried to use Ctrl+C and no effct finally.

9 Answers, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 14 Jun 2017, 03:24 PM
Hi Ning,

Can you please clarify a bit what exact behavior are you aiming at? Is it copying data from the column of RadGridView, or copying data into the cells of the read only column?

Best Regards,
Stefan X1
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
0
Ning
Top achievements
Rank 1
answered on 16 Jun 2017, 01:21 AM

Dear Stefan X1

Just request to copy cell value that corresponding column of RadGridView already set to be read-only into other place such as notepad.

Thanks a lot for your response.

0
Stefan
Telerik team
answered on 20 Jun 2017, 11:56 AM
Hi Ning,

Thanks for the clarification.

You should, however, be able to copy the data from a readonly column unimpededly. Attached to my reply you can find a short video i prepared, that demonstrates this. Can you please check it out? Am I missing something?

Regards,
Stefan X1
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
0
Ning
Top achievements
Rank 1
answered on 03 Jul 2017, 06:45 AM

Dear Stefan X1

I just checked attachment video, and fount that once you select one cell and the whole row will be copied into notepad, actually I just would like to copy pointed cell value into notepad. but I think we have already got the row array value from read-only columns, we can control which one of them used by logical judgement, but for end users, they cannot get excepted cell value through copy, this is really not very good. So any other workround or ideas?

0
Accepted
Stefan
Telerik team
answered on 05 Jul 2017, 07:26 AM
Hi Ning,

You should be able to copy only the value of a given cell by handling the CopyingCellClipboardContent event of RadGridView. This is documented in the Copying help article. May I kindly ask you to give the approach demonstrated in it a try?

I hope it helps.

Regards,
Stefan X1
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
0
Ning
Top achievements
Rank 1
answered on 06 Jul 2017, 08:03 AM

Dear Stefan X1

Thanks a lot for your help.

I used CopyingCellClipboardContent event and found that cannot get current only selected cell.

The CopyingCellClipboardContent  event will hit four times after one row with four columns selected and Ctrl+C command carried out.

I tried to use SelectedCellChanged event to get current selected cell, but failed as supported whole row cells information every time.

I tried to use double-click event to get selected cell, result is good,but it is not very good for the end user.

I tried to set column to be editable and would like to make every commiting action to be cancelled, but I cannot implement it.

And I have no idea how to realize such request.

Maybe I need to change another thinking.

 

0
Stefan
Telerik team
answered on 11 Jul 2017, 05:38 AM
Hello Ning Chen,

In case I am understanding the scenario correctly, you should be able to utilize the SelectedCells property of RadGridView. Can you please check it out?

Regards,
Stefan X1
Progress Telerik
Want to extend the target reach of your WPF applications, leveraging iOS, Android, and UWP? Try UI for Xamarin, a suite of polished and feature-rich components for the Xamarin framework, which allow you to write beautiful native mobile apps using a single shared C# codebase.
0
Ning
Top achievements
Rank 1
answered on 12 Jul 2017, 07:00 AM

Dear Stefan X1

let me try first. once I have progress, I will update such thread.

Thanks a lot.

0
Ning
Top achievements
Rank 1
answered on 13 Jul 2017, 08:23 AM

Dear Stefan X1

We can close the thread and I'm sorry for my no full understanding about RadGridView. The RadGridView Control contains a property called SelectionUnit, If I set it to be Cell or Fixed, that means that everytime once click and post Ctrl+C command, only selected cell value will be copied. It is really very good.

Thanks a lot.

Tags
GridView
Asked by
Ning
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Ning
Top achievements
Rank 1
Share this question
or