

| Type | Description | |||
| Long | A long expression that specifies the width in pixels required to display the entire chart. |
The following VB sample resizes the control so the entire chart is display ( no scroll bars are displayed ):
Private Sub autoSize()
With ChartView1
Dim nMode As ZoomModeEnum
nMode = .ZoomWidthMode
.BeginUpdate
.Width = (2 * .BorderWidth + .ChartWidth) * Screen.TwipsPerPixelX
.Height = (2 * .BorderHeight + .ChartHeight) * Screen.TwipsPerPixelY
.ZoomWidthMode = exControlSize
.ZoomHeightMode = exControlSize
.EndUpdate
.ZoomWidthMode = nMode
.ZoomHeightMode = nMode
End With
End SubThe following VB.NET sample resizes the control so the entire chart is display ( no scroll bars are displayed ):
Private Sub ASize()
With Chartview1
Dim nMode As exontrol.EXORGCHARTLib.ZoomModeEnum = .ZoomWidthMode
.BeginUpdate()
.Width = 2 * Chartview1.BorderWidth + Chartview1.ChartWidth
.Height = 2 * Chartview1.BorderHeight + Chartview1.ChartHeight
.ZoomWidthMode = exontrol.EXORGCHARTLib.ZoomModeEnum.exControlSize
.ZoomHeightMode = exontrol.EXORGCHARTLib.ZoomModeEnum.exControlSize
.EndUpdate()
.ZoomWidthMode = nMode
.ZoomHeightMode = nMode
End With
End SubThe following C# sample resizes the control so the entire chart is display ( no scroll bars are displayed ):
private void autoSize()
{
exontrol.EXORGCHARTLib.ZoomModeEnum nMode = chartview1.ZoomWidthMode;
chartview1.BeginUpdate();
chartview1.Width = 2 * chartview1.BorderWidth + chartview1.ChartWidth;
chartview1.Height = 2 * chartview1.BorderHeight + chartview1.ChartHeight;
chartview1.ZoomWidthMode = exontrol.EXORGCHARTLib.ZoomModeEnum.exControlSize;
chartview1.ZoomHeightMode = exontrol.EXORGCHARTLib.ZoomModeEnum.exControlSize;
chartview1.EndUpdate();
chartview1.ZoomWidthMode = nMode;
chartview1.ZoomHeightMode = nMode;