Spread Windows Forms 7.0 Product Documentation
GetEnumerator(Int32,Int32,Int32,Int32) Method
See Also  Example Support Options
FarPoint.Win.Spread Assembly > FarPoint.Win.Spread.Model Namespace > DefaultSheetSpanModel Class > GetEnumerator Method : GetEnumerator(Int32,Int32,Int32,Int32) Method


row
Row index
column
Column index
rowCount
Number of rows in span
columnCount
Number of columns in span

Glossary Item Box

Gets an enumerator for iterating to the next cell span in the collection after the specified span.

Syntax

Visual Basic (Declaration) 
Public Overloads Overrides Function GetEnumerator( _
   ByVal row As Integer, _
   ByVal column As Integer, _
   ByVal rowCount As Integer, _
   ByVal columnCount As Integer _
) As IEnumerator
Visual Basic (Usage)Copy Code
Dim instance As DefaultSheetSpanModel
Dim row As Integer
Dim column As Integer
Dim rowCount As Integer
Dim columnCount As Integer
Dim value As IEnumerator
 
value = instance.GetEnumerator(row, column, rowCount, columnCount)
C# 
public override IEnumerator GetEnumerator( 
   int row,
   int column,
   int rowCount,
   int columnCount
)

Parameters

row
Row index
column
Column index
rowCount
Number of rows in span
columnCount
Number of columns in span

Return Value

IEnumerator object for enumerating to the next span in the collection

Example

This example moves the models enumerator to the next instance.
C#Copy Code
FarPoint.Win.Spread.Model.DefaultSheetSpanModel defspanModel = new FarPoint.Win.Spread.Model.DefaultSheetSpanModel();
System.Collections.IEnumerator se;
fpSpread1.ActiveSheet.Models.Span = defspanModel;
defspanModel.Add(0, 0, 2, 2);
defspanModel.Add(4, 0, 2, 2);
se = defspanModel.GetEnumerator(4, 0, 2, 2);
listBox1.Items.AddRange(new Object[] {se.MoveNext().ToString(), se.Current.ToString()});
Visual BasicCopy Code
Dim defspanModel As New FarPoint.Win.Spread.Model.DefaultSheetSpanModel()
Dim se As System.Collections.IEnumerator
FpSpread1.ActiveSheet.Models.Span = defspanModel
defspanModel.Add(0, 0, 2, 2)
defspanModel.Add(4, 0, 2, 2)
se = defspanModel.GetEnumerator(4, 0, 2, 2)
ListBox1.Items.AddRange(New Object() {se.MoveNext().ToString(), se.Current().ToString()})

Requirements

Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8

See Also

© 2002-2014 ComponentOne, a division of GrapeCity. All Rights Reserved.