Spread Silverlight Documentation
DragDropBlockEventArgs Class
Members  Example 


Represents the event data for the DragDropBlock event for the GcSpreadSheet component; occurs when a range of cells is being dragged and dropped.
Object Model
DragDropBlockEventArgs Class
Syntax
'Declaration
 
Public Class DragDropBlockEventArgs 
   Inherits System.ComponentModel.CancelEventArgs
'Usage
 
Dim instance As DragDropBlockEventArgs
public class DragDropBlockEventArgs : System.ComponentModel.CancelEventArgs 
Example
This example uses the DragDropBlock event arguments.
gcSpreadSheet1.DragDropBlock += new EventHandler<DragDropBlockEventArgs>(gcSpread1_DragDropBlock);
 gcSpreadSheet1.DragDropBlockCompleted += new EventHandler<DragDropBlockCompletedEventArgs>(gcSpread1_DragDropBlockCompleted);

 void gcSpread1_DragDropBlock(object sender, DragDropBlockEventArgs e)
 {
       if (e.ToRow > 10 || e.ToColumn > 10)
           e.Cancel = true; 
 }

 void gcSpread1_DragDropBlockCompleted(object sender, DragDropBlockCompletedEventArgs e)
  {
       if (e.Copy == true && e.Insert == true)
           MessageBox.Show("Copied insert action has been completed");                     
  }
Private Sub GcSpreadSheet1_DragDropBlock(sender As System.Object, e As GrapeCity.Windows.SpreadSheet.UI.DragDropBlockEventArgs)
        If (e.ToRow > 10 Or e.ToColumn > 10) Then
            e.Cancel = True
        End If
    End Sub

    Private Sub GcSpreadSheet1_DragDropBlockCompleted(sender As System.Object, e As GrapeCity.Windows.SpreadSheet.UI.DragDropBlockCompletedEventArgs)
        If (e.Copy = True And e.Insert = True) Then
            MessageBox.Show("Copied insert action has been completed")
        End If
    End Sub
Inheritance Hierarchy

System.Object
   System.EventArgs
      System.ComponentModel.CancelEventArgs
         GrapeCity.Windows.SpreadSheet.UI.DragDropBlockEventArgs

Requirements

Target Platforms: Windows 7, Windows 8 Desktop, Windows Vista SP1 or later, Windows Server 2000, Windows 2000 Professional, Windows XP Professional, Windows NT 4.0 Workstation, SP6, Windows NT 4.0 Server, SP6

See Also

Reference

DragDropBlockEventArgs Members
GrapeCity.Windows.SpreadSheet.UI Namespace

 

 


Copyright © GrapeCity, inc. All rights reserved.