Spread Windows Forms 12.0 Product Documentation
Sheet Property (TabStripHitTestInformation)
Example 


FarPoint.Win.Spread Assembly > FarPoint.Win.Spread Namespace > TabStripHitTestInformation Class : Sheet Property
Returns the sheet the given location refers to.
Syntax
'Declaration
 
Public ReadOnly Property Sheet As Integer
'Usage
 
Dim instance As TabStripHitTestInformation
Dim value As Integer
 
value = instance.Sheet
public int Sheet {get;}

Property Value

Integer sheet index
Example
This example returns the sheet location.
void fpSpread1SheetTabClick(object sender, SheetTabClickEventArgs e)
{
      Rectangle r = fpSpread1.GetRootWorkbook().GetTabStripRectangle();
      FarPoint.Win.Spread.HitTestInformation hti;
      FarPoint.Win.Spread.TabStripHitTestInformation ti;
      hti = fpSpread1.HitTest(r.X, r.Y);
      ti = hti.TabStripInfo;
      if (hti.Type == HitTestType.TabStrip)
      {
            MessageBox.Show(ti.Sheet.ToString());
      }    
}
Private Sub FpSpread1SheetTabClick(ByVal sender As Object, ByVal e As FarPoint.Win.Spread.SheetTabClickEventArgs)

      Dim r As Rectangle
      r = FpSpread1.GetRootWorkbook.GetTabStripRectangle()

      Dim hti As FarPoint.Win.Spread.HitTestInformation
      Dim ti As FarPoint.Win.Spread.TabStripHitTestInformation
      hti = FpSpread1.HitTest(r.X, r.Y)
      ti = hti.TabStripInfo
      If hti.Type = HitTestType.TabStrip Then
            MsgBox(ti.Sheet)
      End If
See Also

Reference

TabStripHitTestInformation Class
TabStripHitTestInformation Members