curvebase::IsValid

Description

Checks the validity of an Origin C Curve object.

Syntax

BOOL IsValid( )

Parameters

Return

Returns TRUE if Curve object is valid and FALSE if not.

Examples

EX1

int curvebase_IsValid_ex1()
{
    Curve crv;        //Curve is not yet attached and is not valid
    if(crv.IsValid())
        out_str("Curve is valid!");
    else
        out_str("Curve is not valid!");
    Worksheet wks(Project.ActiveLayer());
    crv.Attach(wks,0);    //Curve is now attached and is valid
    if(crv.IsValid())
        out_str("Curve is valid!");
    else
        out_str("Curve is not valid!");
    return 0;
}
//The output is the following:
//Curve is not valid!
//Curve is valid!

Remark

Checks the validity of an Origin C Curve object. Curve objects are valid when they are successfully attached to an internal Origin Worksheet or Graph.

See Also

Curve::Attach

header to Include

origin.h