This question is locked. New answers and comments are not allowed.
Hi,
How can I make the Drag Cue for a RadGridView look like the row I am trying to drag. I am currently creating my own drag cue with the code below but it does not look as good as the row itself. Is there a property on the grid to accomplist this?
Code:
Markup:
Thanks!
How can I make the Drag Cue for a RadGridView look like the row I am trying to drag. I am currently creating my own drag cue with the code below but it does not look as good as the row itself. Is there a property on the grid to accomplist this?
Code:
if (e.Options.Status == DragStatus.DragInProgress) { ContentControl cue = new ContentControl(); cue.ContentTemplate = this.Resources["DraggedItemTemplate"] as DataTemplate; cue.Content = draggedItem; e.Options.DragCue = cue; }Markup:
<DataTemplate x:Key="DraggedItemTemplate"> <StackPanel Orientation="Horizontal" Margin="2" Height="23" Opacity="0.7"> <StackPanel.Background> <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0"> <GradientStop Color="#FFCEAC4E" Offset="1"/> <GradientStop Color="#FFD4B31A"/> </LinearGradientBrush> </StackPanel.Background> <TextBlock Text="{Binding Name}" FontWeight="Bold" Margin="5,3,0,0" /> <TextBlock Text="{Binding Age}" Foreground="Gray" Margin="10,3,0,0" /> <TextBlock Text="{Binding Department}" Foreground="Gray" Margin="15,3,0,0" /> <TextBlock Text="{Binding Salary}" Foreground="Gray" Margin="20,3,0,0" /> </StackPanel> </DataTemplate>Thanks!