Promotic
WikipediaLinkedInYoutubeTwitterFacebook

SetValidityFce - method of object tvGraph

Description:
Sets the validity function for the tvGraph object. Data points of the trend (see tvPoints) are checked by each object of the tvGraph type (there can be created more objects in the object of the tvTrend type, see tvTrend.AddGraph) and the time range where data points satisfy the validity function of one in graphs, is drawn just by the tvGraph object.

The SetValidityFce function needn't be called in most cases because the validity function is also set on creating the tvGraph object while calling the tvTrend.AddGraph where it is entered as a parameter.

Syntax:
SetValidityFce(sValidityFce As String) As Long
Calling:
oGraph.SetValidityFce sValidityFce
Parameters:
sValidityFce(String) In the following text the xx has the following meanings:

gt=greater than, ge=greater or equal, eq=equal, le=less or equal, lt=less than.

In the following text the real number is set into val.

"LimitVal(xx;val)" - time interval of the trend is drawn if values of data points in the tvPoints object exceed (equal, under pass, see xx) the real value val.

Example: "LimitVal(gt;100)"

"LimitTrend(xx;t1)" - time interval of the trend is drawn if values of data points in the tvPoints object exceed (equal, under pass, see xx) values of data points of another trend whose tvTrend.ID equal t1.

Example: "LimitTrend(gt;t1)"

"LimitTrendCompare(xx;t1;val)" - time interval of the trend is drawn if values of data points of another trend (tvTrend.ID equal t1) exceed (equal, under pass, see xx) the real value val.

Example: "LimitTrendCompare(gt;t1;100)"

"AlwaysTrue" - time interval of the trend is always drawn
"AlwaysFalse" - time interval of the trend is never drawn
Return Values:
0 - syntax error, the validity function was not set
1 - the validity function "AlwaysFalse" was set correctly
2 - the other validity function was set correctly
Note:
See the configurator "Validity".
See also:
Example1:
Dim n
n = oGraph.SetValidityFce("LimitTrend(gt;100)")
If n>0 Then
' OK
End If
Example2:
oGraph.SetValidityFce "LimitTrend(gt;t1)"
Example3:
oGraph.SetValidityFce "LimitTrend(gt;t1;0)"
© MICROSYS, spol. s r. o.Tavičská 845/21 703 00 Ostrava-Vítkovice