Spread WPF Documentation
GrapeCity.Windows.SpreadSheet.Data Namespace / Worksheet Class / GetViewportWidth Method
The index of the column viewport.
Example


In This Topic
    GetViewportWidth Method
    In This Topic
    Gets the width of the viewport.
    Syntax
    'Declaration
     
    Public Function GetViewportWidth( _
       ByVal columnViewportIndex As Integer _
    ) As Double
    'Usage
     
    Dim instance As Worksheet
    Dim columnViewportIndex As Integer
    Dim value As Double
     
    value = instance.GetViewportWidth(columnViewportIndex)
    public double GetViewportWidth( 
       int columnViewportIndex
    )

    Parameters

    columnViewportIndex
    The index of the column viewport.

    Return Value

    The width of the viewport.
    Example
    This example uses the GetViewportWidth method.
    listBox1.Items.Add(gcSpreadSheet1.Sheets[0].GetViewportHeight(0).ToString());
    listBox1.Items.Add(gcSpreadSheet1.Sheets[0].GetViewportInfo().ColumnViewportCount.ToString());
    listBox1.Items.Add(gcSpreadSheet1.Sheets[0].GetViewportLeftColumn(0).ToString());
    listBox1.Items.Add(gcSpreadSheet1.Sheets[0].GetViewportTopRow(0).ToString());
    listBox1.Items.Add(gcSpreadSheet1.Sheets[0].GetViewportWidth(0).ToString());
    ListBox1.Items.Add(GcSpreadSheet1.Sheets(0).GetViewportHeight(0).ToString())
    ListBox1.Items.Add(GcSpreadSheet1.Sheets(0).GetViewportInfo.ColumnViewportCount.ToString())
    ListBox1.Items.Add(GcSpreadSheet1.Sheets(0).GetViewportLeftColumn(0).ToString())
    ListBox1.Items.Add(GcSpreadSheet1.Sheets(0).GetViewportTopRow(0).ToString())
    ListBox1.Items.Add(GcSpreadSheet1.Sheets(0).GetViewportWidth(0).ToString())
    See Also