Spread for ASP.NET 10 Product Documentation
IsRowUsed Method (IOptimizedEnumerationSupport)
Example 


Row index
Determines whether a row had data in any of the cells in that row.
Syntax
'Declaration
 
Function IsRowUsed( _
   ByVal row As Integer _
) As Boolean
'Usage
 
Dim instance As IOptimizedEnumerationSupport
Dim row As Integer
Dim value As Boolean
 
value = instance.IsRowUsed(row)
bool IsRowUsed( 
   int row
)

Parameters

row
Row index

Return Value

true if the row has data; otherwise, false
Example
FarPoint.Web.Spread.Model.IOptimizedEnumerationSupport oes;
Random r = new Random(); 
int countc, countr; 
int i, j; 
for (i = 0; i<=1; i++) 
{ 
     for (j = 0; j<=2; j++) 
          FpSpread1.ActiveSheetView.SetValue(i, j, r.Next(1, 200).ToString()); 
} 
oes = (FarPoint.Web.Spread.Model.IOptimizedEnumerationSupport)FpSpread1.ActiveSheetView.DataModel; 
bool b = oes.IsRowUsed(2);
string msg = "The row used is " + b.ToString();
Response.Write("<script language='javascript'>alert('" + msg + "')</script>");
Dim oes As FarPoint.Web.Spread.Model.IOptimizedEnumerationSupport
Dim r As New Random
Dim i, j As Integer
Dim countc, countr As Integer
For i = 0 To 1
     For j = 0 To 2
          FpSpread1.ActiveSheetView.SetValue(i, j, r.Next(1, 200).ToString())
     Next j
Next i
oes = FpSpread1.ActiveSheetView.DataModel
Dim b As Boolean = oes.IsRowUsed(2)
Dim msg As String = "The row used is " & b.ToString()
Response.Write("<script language='javascript'>alert('" & msg & "')</script>")
Requirements

Target Platforms: Windows 7, Windows 8, Windows 10, Windows Vista, Windows Server 2003, Windows Server 2008, Windows Server 2012, Windows XP Professional

See Also

Reference

IOptimizedEnumerationSupport Interface
IOptimizedEnumerationSupport Members

 

 


Copyright © GrapeCity, inc. All rights reserved.