See Also

CustomControl Class  | CustomControl Members  | Walkthrough: Custom Controls and ChartFX

Language

Visual Basic

C#

Show All

See Also Languages ActiveReports Send feedback to Data Dynamics

Control Property

Gets or sets a reference to the hosted control.

[Visual Basic]
Public ReadOnly Property Control As Object
[C#]
public object Control {get;}

Remarks

You can use this method to set the properties of the hosted control.  ActiveReports does not provide direct access to hosted custom controls at design time.

Example

[C#] 

private void Detail_Format(object sender, System.EventArgs eArgs) 

    System.Random r = new System.Random(); 
    Chart Chart1 = new Chart(); 
    //Cast customControl as ChartFX chart 
    Chart1 = ((SoftwareFX.ChartFX.Chart)this.CustomControl1.Control); 
    //Open the communication channel 
    Chart1.OpenData(SoftwareFX.ChartFX.COD.Values, 3, 3); 
 
    for (int i=0;i<3;i++) 
    { 
        for (int j=0;j<3;j++) 
        { 
            //Assign the values to the series selected 
            Chart1.Value[i, j] = r.NextDouble() *  100; 
        } 
    } 
    //Close the communication channel 
    Chart1.CloseData(SoftwareFX.ChartFX.COD.Values); 
}

[Visual Basic] 

Private Sub Detail_Format(ByVal sender As Object, ByVal e As System.EventArgs) Handles Detail.Format
    Dim r As New System.Random()
    Dim Chart1 As SoftwareFX.ChartFX.Chart
    'Cast customControl as ChartFX chart
    Chart1 = CType(Me.CustomControl1.Control, SoftwareFX.ChartFX.Chart)

    Dim i As Integer
    Dim j As Integer

    'Open the communication channel
    Chart1.OpenData(SoftwareFX.ChartFX.COD.Values, 3, 3)
    For i = 0 To 2
        For j = 0 To 2
            'Assign the values to the series selected
            Chart1.Value(i, j) = r.NextDouble() * 100
        Next j
    Next i
    'Close the communication channel
    Chart1.CloseData(SoftwareFX.ChartFX.COD.Values)
End Sub

See Also

CustomControl Class  | CustomControl Members  | Walkthrough: Custom Controls and ChartFX

 

 


Copyright © 2004-2005 Data Dynamics, Ltd. All rights reserved.