You can access the Form which hosts the ControlBar by using the C1ZoomCommandProvider.OwnerForm property. Use the following code to close the Form.
C# |
Copy Code
|
---|---|
c1ZoomCommandProvider1.OwnerForm.Close(); |
Visual Basic |
Copy Code
|
---|---|
C1ZoomCommandProvider1.OwnerForm.Close() |
You can access the C1Zoom component which is in the Form by using the C1ZoomCommandProvider.OwnerGcZoom property. Use the following code to scroll to the right-down direction.
C# |
Copy Code
|
---|---|
private void button1_Click(object sender, EventArgs e) { C1ZoomCommandProvider c1ZoomCommandProvider1 = new C1ZoomCommandProvider(); } |
Visual Basic |
Copy Code
|
---|---|
Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim currentLocation As Point = C1ZoomCommandProvider1.OwnerGcZoom.ScrollLocation currentLocation.X -= 100 currentLocation.Y -= 100 C1ZoomCommandProvider1.OwnerGcZoom.ScrollLocation = currentLocation End Sub |