Spread for ASP.NET 10 Product Documentation
DefaultColumnWidth Property
Example 


Gets or sets the default column width in pixels for all columns in the sheet.
Syntax
'Declaration
 
Public Property DefaultColumnWidth As Integer
'Usage
 
Dim instance As SheetView
Dim value As Integer
 
instance.DefaultColumnWidth = value
 
value = instance.DefaultColumnWidth
public int DefaultColumnWidth {get; set;}

Property Value

Integer number of pixels of the default column width
Remarks

Set this property to specify the width in pixels for all columns in the sheet. If you want to specify the width for a particular column in the sheet, use the SetColumnWidth method or the Width method for a Column object.

To set the height for all rows in the sheet, set the DefaultRowHeight property.

Example
This example changes the default settings for the width of columns and height of rows of a sheet.
FarPoint.Web.Spread.SheetView sv=FpSpread1.ActiveSheetView;
sv.DefaultColumnWidth=120;
sv.DefaultRowHeight=30;
Dim sv As FarPoint.Web.Spread.SheetView
sv=FpSpread1.ActiveSheetView
sv.DefaultColumnWidth=120
sv.DefaultRowHeight=30
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

SheetView Class
SheetView Members
SetColumnWidth Method
DefaultRowHeight Property
GetColumnWidth Method
Width Property

User-Task Documentation

Setting the Column Width

 

 


Copyright © GrapeCity, inc. All rights reserved.