Constants:
- zsPageWidth = 0 (Long)
- zsPageHeight = 1 (Long)
- zsSelection = 2 (Long)
This interface allows managing a chart object. E.g. a patient visit data field can be passed to ITXChart.YField to be drawn on the chart.
It allows also the access to the reference list, the line references and the shadow references.
The list of available properties is detailed on the <a href="#GraphObjIntf-ITXChart-Properties">Properties</a> help.
Other objects that are not (yet) published can be accessed through the <a href="#GraphObjIntf-ITXChart-Objects">Objects</a> property.
This class implements a collection that contains the graph sheet's chart list objects (<a href="#GraphObjIntf-ITXChart">ITXChart</a>).
The charts can be accessed by their names or indexes (using the Item property).<br/>
The Count property can be used to retrieve the number of the charts.
[+] Example
[Delphi]
var
AChartList: ITXChartList;
I: Integer;
begin
AChartList := AGraphOcx.GraphSheet.Charts;
for I:= 0 to AChartList.Count-1 do
ShowMessage(AChartList[I].Name);
end;
[VB]
Dim AChartList As ITXChartList, I As Integer
Set AChartList = AGraphOcx.GraphSheet.Charts
For I = 0 to AChartList.Count-1
MsgBox AChartList(I).Name
End For
ITXCustomObjectList is a base class for all the graph object lists or collections.
Count contains the number of elements existing in the Objects 0-based list.<br/>
<br/>
Normally the descendant Objects list should be used.<br/>
For each ITXCustomObjectList descendant, the items can be accessed by:
<ul>
<li>Name</li>
<li>Index</li>
</ul>
In Visual Basic, the items can be accessed using the "For Each" syntax, see example below.
[+] Example
[VB]
1. Using For
Dim AList As ITXCustomObjectList
Set AList = AGraphOcx.GraphSheet.Charts
For i = 0 To AList.Count - 1
MsgBox AList.Objects(i).Name
Next i
2. Using For Each
Dim AList As ITXCustomObjectList
Dim AObject As ITXObject
Set AList = AGraphOcx.GraphSheet.Charts
For Each AObject In AList
MsgBox AObject.Name
Next AObject
This class implements an item of a <a href="#GraphObjIntf-ITXDataFieldDefList">ITXDataFieldDefList</a> collection.<br/>
The Title, UnitName and DisplayFormat properties are used whenever field information is shown on the graph. The DisplayFormat is used to control the way the value of the field is shown. It must be set according to field's type (float, date etc).
[+] Example
[Delphi]
with AGraphOcx.PatientData.FieldDef['FatherHeight'] do
begin
Title := 'Father''s height';
UnitName := 'cm';
DisplayFormat := '0.00';
end;
with AGraphOcx.VisitData.FieldDef['DateVisit'] do
begin
Title := 'Visit date';
DisplayFormat := 'yyyy/mm/dd';
end;
[VB]
With AGraphOcx.PatientData.FieldDefs("FatherHeight")
.Title = "Father's height"
.UnitName = "cm"
.DisplayFormat = "0.00"
End With
With AGraphOcx.VisitData.FieldDefs("DateVisit")
.Title = "Visit date"
.DisplayFormat = "yyyy/mm/dd"
End With
This class implements a collection that contains field definitions. It is a descendant of <a href="#GraphObjIntf-ITXCustomObjectList">ITXCustomObjectList</a>.
It is used by ITXPatientData and ITXVisitDataList classes.
The collection contains <a href="#GraphObjIntf-ITXDataFieldDef">ITXDataFieldDef</a> items.
This class allows choosing the graph template to be drawn on the current sheet. <br/>
The normal use case is to select a template from TemplatesList, then a GraphType from GraphTypesList and finally an AgeRange from AgeRangesList.<br/><br/>
Tables with all available Template, GraphType and AgeRange for each specific component are available at the end of this documentation:<br/>
<ul>
<li><a href="#AustrianGrowthCharts-IAustrianGrowthChartsGraph">AT (Austrian)</a></li>
<li><a href="#BelgianGrowthCharts-IBelgianGrowthChartsGraph">BE (Belgian)</a></li>
<li><a href="#CanadianGrowthCharts-ICanadianGrowthChartsGraph">CA (Canadian)</a></li>
<li><a href="#FrenchGrowthCharts-IFrenchGrowthChartsGraph">FR (French)</a></li>
<li><a href="#GermanGrowthCharts-IGermanGrowthChartsGraph">DE (German)</a></li>
<li><a href="#IcelandicGrowthCharts-IIcelandicGrowthChartsGraph">IS (Icelandic)</a></li>
<li><a href="#NorwegianGrowthCharts-INorwegianGrowthChartsGraph">NO (Norwegian)</a></li>
<li><a href="#SwedishGrowthCharts-ISwedishGrowthChartsGraph">SE (Swedish)</a></li>
<li><a href="#UKGrowthCharts-IUKGrowthChartsGraph">UK</a></li>
<li><a href="#WHOGrowthCharts-IWHOGrowthChartsGraph">WHO</a></li>
<li><a href="#USGrowthCharts-IUSAllGraph">USA</a></li>
</ul>
<br/>
Call ApplyAttributes so that the current sheet uses the new attributes.
[+] Example
[VB]
'US specific example
Set Graph = Server.CreateObject("USGrowthCharts.USAllGraph")
'Show the US Individual "BMI 2-20 yrs" chart
With Graph.GraphAttributes
.template = 0 '0 - USA
.graphtype = 0 '0 - Individual
.agerange = 2 '5 - BMI 2-20 yrs
.ApplyAttributes
End With
[VB]
'WHO specific example
Set Graph = Server.CreateObject("WHOGrowthCharts.XWHOGrowthCharts")
'Show the WHO "BMI 2-5 years" chart
With Graph.GraphAttributes
.template = 0 '0 - WHO
.graphtype = 1 '1 - 2-5 years
.agerange = 2 '2 - BMI 2-5 yrs
.ApplyAttributes
End With
<div style="float: right">
<img src="images/GrowthCharts_GraphSheetCharts.png" title="Graph Sheet and Charts" style="width: 300px"/><br/>
<span style="color: #909090">Fig. Graph Sheet and Charts</span>
</div>
This class represents the active graph sheet. The active graph sheet is a page configured with components such as patient header, reference information and versioning footer and one or more charts.<br/><br/>
The Properties, Charts, Objects and Tools collection properties can be used to customize the sheet's look or its behavior.<br/>
<br/>
The Properties and Tools give access to customizations, options and actions usually available via toolbars, menus and mouse actions when the component is integrated in an interactive client (desktop application).<br/><br/>
The list of available properties is detailed on the <a href="#GraphObjIntf-ITXGraphSheet-Properties" title="Properties">Properties</a> help.<br/>
The Tools, such as the PreviewToolBar and the SettingsDialog, are detailed <a href="#GraphObjIntf-ITXToolList" title="ITXToolList">here</a>.<br/>
It is the main ancestor of almost all graph classes. Use Properties property to access all objects' properties.
This is the object list class usable in a "For Each" VB syntax.
This interface allows the access to any field belonging to PatientData. Whenever a field value needs to be got or set, the field must be passed using field's name as the parameter of Field property.<br/><br/>
The following patient data fields are available in the Growth Chart component:<br/>
<!--Read/Write fields:-->
<ul>
<li>ID - Identity of the child, patient file or country-specific personal number (e.g. SE or NO personnummer).</li>
<li>Surname - Surname of the child</li>
<li>FirstName - First name of the child</li>
<li>IsMale - Important boolean that decides if the layouts and references should be for boys or girls</li>
<li>BirthDate - Patient's date of birth</li>
<li>Sex - Text used to display the sex of the child. Different for each version, see below.</li>
<li>GAWeeks - The child's gestational age (integer, completed weeks). Title: "GA weeks".</li>
<li>GADays - The child's gestational age (integer, days in addition to the weeks above). Title: "GA days".</li>
<li>BL - Birth length (double, in cm)</li>
<li>BW - Birth weight (double, in kg)</li>
<li>BHCirc - Birth head circumference (double, in cm)</li>
<li>MotherHeight - Height of the mother (double, in cm)</li>
<li>MotherWeight - Weight of the mother (double, in kg)</li>
<li>MotherHC - Mother's head circumference (double, in cm)</li>
<li>FatherHeight - Height of the father (double, in cm)</li>
<li>FatherWeight - Weight of the father (double, in kg)</li>
<li>FatherHC - Father's head circumference (double, in cm)</li>
<li>Notes - doctor notes on the patient file</li>
<li>Twin - multiple births</li>
<li>Adopted - boolean showing that the patient was adopted</li>
<li>MenarcheDate - patient's Menarche date</li>
<li>ShowAllPubInfo - (deprecated) This field is now always True, and that means that all available pubertal information are plotted in the puberty graph section.</li>
</ul>
<!--
<br></br>
Read-only fields (calculated)
<br></br>
<ul>
<li>TargetHeight - Target height (or mid parental height)</li>
<li>BLSDS - Birth length SDS</li>
<li>BWSDS - Birth weight SDS</li>
<li>BHCircSDS - Birth head circumference SDS</li>
<li>BLPerc - Birth length percentile</li>
<li>BWPerc - Birth weight percentile</li>
<li>BHCircPerc - Birth head circumference percentile</li>
<li>MotherBMI - Mother's BMI</li>
<li>FatherBMI - Father's BMI</li>
<li>MotherHeightSDS - Mother's Height SDS</li>
<li>MotherWeightSDS - Mother's Weight SDS</li>
<li>MotherHCSDS - Mother's head circumference SDS</li>
<li>FatherHeightSDS - Father's Height SDS</li>
<li>FatherWeightSDS - Father's Weight SDS</li>
<li>MotherBMISDS - Mother's BMI SDS</li>
<li>FatherBMISDS - Father's BMI SDS</li>
<li>FatherHCSDS - Father's head circumference SDS</li>
<li>TargetHeightSDS - Target Height SDS</li>
<li>TargetHeightPerc - Target height percentile</li>
<li>MHeightPerc - Mother's height percentile</li>
<li>MWeightPerc - Mother's weight percentile</li>
<li>MHeadCircPerc - Mother's head circumference percentile</li>
<li>MBMIPerc - Mother's BMI percentile</li>
<li>FHeightPerc - Father's height percentile</li>
<li>FWeightPerc - Father's weight percentile</li>
<li>FHeadCircPerc - Father's head circumference percentile</li>
<li>FBMIPerc - Father's BMI percentile</li>
</ul>
-->
<br/>
The Patient Sex label text depends on the chart component version:
<ul>
<li>US - Male, Female</li>
<li>Swedish - Pojke, Flicka</li>
<li>Norwegian - Gutt, Jente</li>
<li>Icelandic - Karlkyns, Kvenkyns</li>
<li>WHO - Male, Female</li>
</ul>
<br/>
If the GAWeeks value is unknown, to be able to plot birth size values on premature charts, set the value to 40 weeks.
[+] Example
[VB]
AGraphOcx.PatientData.Field("BirthDate") = #6/1/2010#
[Delphi]
AGraphOcx.PatientData.Field['BirthDate'] := EncodeDate(2010, 06, 01);
//change the SurName label for tables and legend
AGraphOcx.PatientData.FieldDefs['SurName'].Title := 'New Surname Title';
Changed;
This class represents a reference and gives access to reference properties such as Description and Publication.
[+] Example
[Delphi]
var
AReference: ITXReference;
begin
AReference := AGraphOcx.GraphSheet.Charts['Bottom'].References[0];
ShowMessage(AReference.Name);
end;
[VB]
Dim AReference As ITXReference
Set AReference = AGraphOcx.GraphSheet.Charts("Bottom").References(0)
MsgBox (AReference.Name)
Derived from ITXCustomObjectList, it contains a list of available references.
The Item property (default property) it gives access to a <a href="#GraphObjIntf-ITXReference">reference</a> object.
The references can be accessed by their names or indexes.
The Count property can be used to retrieve the number of the references.
[+] Example
[VB]
1. Using enumeration syntax
'this code sample fills-up a previously defined combobox with all available references
Dim AReference As ITXReference
With AGraphOcx.GraphSheet.Charts("ChartName")
For Each AReference In .References
ComboBox1.AddItem (AReference.Name)
Next AReference
End With
2. By name
'this code sample sets a chart's reference
Dim AReference As ITXReference
With AGraphOcx.GraphSheet.Charts("ChartName")
Set AReference = .References("ReferenceName")
End With
This object contains a templates list. It is used by the <a href="#GraphObjIntf-ITXGraphAttributes">graph attributes</a> object to manage the available templates on the current sheet.
[+] Example
[VB]
'this code shows all available templates
Dim ATemplates As ITXTemplateItemList
Set ATemplates = AGraphOcx.GraphAttributes.TemplatesList
For i = 0 To ATemplates.Count - 1
MsgBox (ATemplates.Names(i))
Next i
This class implements an item from the ITXToolList collection, giving access to one of the graph sheet tool items.
This class implements a collection that contains the graph sheet's tool list object (<a href="#GraphObjIntf-ITXTool">ITXTool</a>). Available tools are: PreviewToolBar, SettingsDialog and SettingsObject.<br/>
<br/>
<span class="bold">PreviewToolBar</span><br/>
The PreviewToolBar tool allows managing the toolbar buttons and executing the corresponding button actions. <br/>
The Show* properties allow showing and hiding a button.<br/>
The Enable* properties allow enabling and disabling a button.<br/>
The other properties execute the respective actions or return results depending on their meaning (PageNo returns current page number, PageNo = 5 goes to page 5 if possible).<br/>
<br/>
The tool has the following Properties:
<ul>
<li>Active - shows/hides the whole toolbar</li>
<li>FirstPage - set True to go to the first page (for multiple-page charts); returns True if already on the first page</li>
<li>ShowFirstPage - show/hide the FirstPage button</li>
<li>EnableFirstPage - enable/disable the FirstPage button</li>
<li>LastPage - set True to go to the last page (for multiple-page charts); returns True if already on the last page</li>
<li>ShowLastPage - show/hide the LastPage button</li>
<li>EnableLastPage - enable/disable the LastPage button</li>
<li>PrevPage - set True to go to the previous page (for multiple-page charts)</li>
<li>ShowPrevPage - show/hide the PrevPage button</li>
<li>EnablePrevPage - enable/disable the PrevPage button</li>
<li>NextPage - set True to go to the next page (for multiple-page charts)</li>
<li>ShowNextPage - show/hide the NextPage button</li>
<li>EnableNextPage - enable/disable the NextPage button</li>
<li>PageNo - set to an integer (starting from 0) to go to a specific page number (for multiple-page charts); returns the current page number</li>
<li>ShowPageNo - show/hide the PageNo</li>
<li>EnablePageNo - enable/disable the PageNo</li>
<li>PageCount - returns page count (for multiple-page charts this is bigger than 1)</li>
<li>ShowPageCount - show/hide the PageCount button</li>
<li>EnablePageCount - enable/disable the PageCount button</li>
<li>ZoomPage - set to True to fit the chart page to the current form</li>
<li>ShowZoomPage - show/hide the ZoomPage button</li>
<li>EnableZoomPage - enable/disable the ZoomPage button</li>
<li>ZoomPageWidth - set to True to fit the chart page to the current form width</li>
<li>ShowZoomPageWidth - show/hide the ZoomPageWidth button</li>
<li>EnableZoomPageWidth - enable/disable the ZoomPageWidth button</li>
<li>ZoomPageHeight - set to True to fit the chart page to the current form height</li>
<li>ShowZoomPageHeight - show/hide the ZoomPageHeight button</li>
<li>EnableZoomPageHeight - enable/disable the ZoomPageHeight button</li>
<li>ZoomNavigation - set to True to show the chart page navigation control</li>
<li>ShowZoomNavigation - show/hide the ZoomNavigation control</li>
<li>EnableZoomNavigation - enable/disable the ZoomNavigation control</li>
<li>Print - set to True to print the all the chart pages</li>
<li>ShowPrint - show/hide the Print button</li>
<li>EnablePrint - enable/disable the Print button</li>
<li>Export - set to True to Export all the chart pages (format available in the Export dialog)</li>
<li>ShowExport - show/hide the Export button</li>
<li>EnableExport - enable/disable the Export button</li>
<li>Copy - set to True to Copy the current chart page to clipboard</li>
<li>ShowCopy - show/hide the Copy to clipboard button</li>
<li>EnableCopy - enable/disable the Copy to clipboard button</li>
<li>Settings - set to True to show the Settings dialog</li>
<li>ShowSettings - show/hide the Settings button</li>
<li>EnableSettings - enable/disable the Settings button</li>
</ul>
<br/>
<span class="bold">SettingsDialog</span><br/>
The SettingDialog tool allows showing the settings dialog. The tool has the following Properties:
<ul>
<li>Active</li>
</ul>
<br/>
<span class="bold">SettingsObject</span><br/>
The SettingsObject tool allows directly managing the settings. <br/>
The Show/Hide* properties allow showing and hiding a graph feature.<br/>
The Selected* properties allow selecting a specific option for a graph feature.<br/>
Some of the settings are only available on specific charts. <br/>
<br/>
The tool has the following Properties:
<ul>
<li>HideData - Show/hide all the patient's data</li>
<li>Anonymous: Boolean - Show/hide patient's names and ID</li>
<li>ShowParentalHeights - Show/hide patental measurements and right-side points</li>
<li>ShowPubertalSection - Show/hide pubertal section on the page</li>
<li>ShowCorrectedAge - Show/hide corrected age curve (where applicable)</li>
<li>ShowAllPubInfo - Show/hide </li>
<li>ShowBoneAgeLabel - Show/hide bone age labels</li>
<li>ShowBoneAge - Show/hide bone ages</li>
<li>ShowTodayLine - Show/hide today line</li>
<li>ShowComments - Show/hide comments</li>
<li>ShowRefShadow - Show/hide secondary growth reference</li>
<li>ShowSortDescending - Show ascending/descending dates in the tables</li>
<li>ShowGridVisits - Show/hide data table</li>
<li>HideGraphLine - Show/hide line connecting the curve points</li>
<li>ShowEvents - Show/hide events line</li>
<li>ShowLongIntervals - Draw lines between distant measurements using a lighter color</li>
<li>ShowIOTF35_40 - Show/hide BMI 35 and 40 IOTF lines</li>
<li>ShowSIUnits - Switch from metrics to US imperial units</li>
<li>SelectedLanguage - Select the chart's language, depending on country and available translations</li>
<li>SelectedAgeRange - Select age range for measurement and calculation charts (0 = 1 year, 1 = 20 years,)</li>
<li>SelectedRefSet - Show percentile or SD reference lines (0 = 5 to 95 percentiles, 1 = 3 to 97 percentiles, 2 = SDS)</li>
</ul>
<br/>
See some examples below.
[+] Example
[VB]
With AGraphOcx.GraphSheet.Tools("PreviewToolBar")
'hides ZoomPage button from the toolbar
.ShowZoomPage = False
'print current page
.Print = True
'hide toolbar
.Active = False
End With
[Delphi]
V:= GraphX.GraphSheet.Tools['SettingsObject'];
V.ShowCorrectedAge:= not V.ShowCorrectedAge;
V.ShowCurveDiscontinuity:= not V.ShowCurveDiscontinuity;
V.Apply:= True;
This interface allows managing patient visits' data. Each field can be accessed using the Field property.<br/>
Visit fields accessible using the Field("field name") syntax:<br/><br/>
Read/Write fields
<br/>
<ul>
<li>DateVisit - The date of the measurement</li>
<li>CA - The chronological age in years at the date of measurement (calculated by the ActiveX)</li>
<li>Height - Height of the child (double, in cm)</li>
<li>Weight - Weight of the child (double, in kg)</li>
<li>HeadCirc - The child's head circumference (double, in cm)</li>
<li>Menarche - A boolean value indicating that this is the date of menarche (deprecated)</li>
<li>PH - Pubic hair stage (integer, 1-5) for this visit</li>
<li>BG - Breast stage (girls) or genital stage (boys) (integer, 1-5)</li>
<li>TestisL - Left testicular volume (integer, in mL)</li>
<li>TestisR - Right testicular volume (integer, in mL)</li>
<li>Testis - (Norwegian only)</li>
<li>PubertySelfEstimate - Text that can be used to indicate if pubertal development is self-estimated or not.</li>
<li>Comment - Free text comment to this visit</li>
<!--li>CAWeeks - internal</li-->
<li>SitHeight: Sitting height (double, in cm)</li>
<li>Span - Arm span (double, in cm)</li>
<li>Foot - Foot length (double, in cm)</li>
<li>Waist - Waist circumference (double, in cm)</li>
<li>BA - Bone age in years for the child at this date. This draws a bone age marker on the chart for this visit</li>
<li>BAType - Bone age method. Possible values and their corresponding default labels are: 0 (G&P), 1 (TW2), 2 (RUS), 3 (Other)</li>
<li>BATypeName - Used to override the BAType default labels (G&P, TW2, RUS or Other)</li>
<li>BAGP - Bone age G&P (double, in years)</li>
<li>BATW2 - Bone age TW II (20 bones) (double, in years)</li>
<li>BATW2RUS - Bone age TW II RUS (double, in years)</li>
<li>BATW3RUS - Bone age TW III RUS (double, in years)</li>
<li>MeasuredAt - where the child was measured (e.g. city, hospital, doctor)</li>
<li>HeightMeasureType - the way the child was measured: recumbent (1) or standing (2)</li>
</ul>
<br/>
Read-only fields (calculated)
<br/>
<ul>
<!--
<li>HV - Height velocity</li>
<li>BMI - Body mass index. This field is calculated automatically</li>
<li>SitHeightSDS - Sitting height SDS</li>
<li>HeightSDS - Height SDS</li>
<li>HeightPerc - Height percentile</li>
<li>WeightSDS - Weight SDS</li>
<li>WeightPerc - Weight percentile</li>
<li>HeadCircSDS - Head circumference SDS</li>
<li>HeadCircPerc - Head circumference percentile</li>
<li>BMISDS - BMI SDS</li>
<li>BMIPerc - BMI percentile</li>
-->
<li>LegLength - Leg length (double, in cm)</li>
<!--
<li>LegLengthSDS - Leg length SDS</li>
<li>LegLengthPerc - Leg length percentile</li>
<li>HVSDS - Height velocity SDS</li>
<li>HVPerc - Height velocity percentile</li>
<li>HVSit: Sitting height velocity</li>
<li>HVSitSDS - Sitting height velocity SDS</li>
<li>HVSitPerc - Sitting height velocity percentile</li>
<li>HVLegLength - Leg length velocity</li>
<li>HVLegLengthSDS - Leg length velocity SDS</li>
<li>HVLegLengthPerc - Leg length velocity percentile</li>
-->
<li>SHH - Relative sitting height (double, in cm)</li>
<!--
<li>SHHSDS - Relative sitting height SDS</li>
<li>SHHPerc - Relative sitting height percentile</li>
<li>SpanSDS - Arm span SDS</li>
<li>SpanPerc - Arm span percentile</li>
<li>FootSDS - Foot length SDS</li>
<li>FootPerc - Foot length percentile</li>
<li>WaistSDS - Waist circumference SDS</li>
<li>WaistPerc - Waist circumference percentile</li>
<li>WFH - Weight for height</li>
-->
</ul>
See below an example how to get a visit field's value.
[+] Example
[VB]
With AGraphOcx.VisitData(0)
MsgBox "Date " + Str(.Field("DateVisit")) + " : Height = " + Str(.Field("Height"))
End With
This class implements a collection that contains the patient's visit data objects (<a href="#GraphObjIntf-ITXVisitDataList">ITXVisitData)</a>. The visit objects can be created and added to the list using the New method and listed and accessed using the Item and Count properties.
[+] Example
[VB]
Set Graph = Server.CreateObject("USGrowthCharts.USAllGraph")
with Graph
'adds all visits in a list
'e.g. Date: 02/04/2008; Height: 120 cm
listVisits.Clear
Dim AItem As String
For i = 0 To .VisitData.Count - 1
AItem = "Date: " + Str(.VisitData(i).Field("DateVisit"))
If .VisitData(i).Field("Height") Then
AItem = AItem + "; " + .VisitData.FieldDefs("Height").Title + _
": " + Str(.VisitData(i).Field("Height")) + _
" " + .VisitData.FieldDefs("Height").UnitName
End If
listVisits.AddItem (AItem)
Next i
end with
[VB]
With AGraphOcx.VisitData(0)
MsgBox "Date " + Str(.Field("DateVisit")) + " : Height = " + Str(.Field("Height"))
End With
This class is the base class for all visible objects. E.g. ITXChart is a descendant of ITXVisualObject.