Create
Create an internal Origin data set (may or may not be temporary).
BOOL Create( int Size, UINT Option = 0 )
Returns TRUE on successful exit and FALSE on error.
EX1
void Curve_Create_ex1() { int ii; LT_execute("list s;"); { Curve crv0; crv0.Create(3); // Size=3 & Option=0 by default (create and attach to temporary data set) for(ii = 0; ii < 3; ii++) crv0[ii] = ii; } LT_execute("list s;"); // Out of crv0's scope, note new crv0 TEMP_ data set is destroyed Curve crv1; crv1.Create(3,1); // Size=3 & Option=1 (create and attach to a second data set that is not temporary) for(ii = 0; ii < 3; ii++) crv1[ii] = ii; LT_execute("list s;"); // Note new crv1 TEMP_ data set crv1.Destroy(); // Destroy crv1 TEMP_ data set (comment out this line and TEMP_ data set does not get deleted) LT_execute("list s;"); // Note new crv1 TEMP_ data set is destroyed (or not if above line is commented out) }
Create a temporary (or permanent) Origin data set and attach the Dataset object to it. If Option=1 is specified and data set is not destroyed by calling the Dataset::Destroy method the data set will remain in Origin after the Origin C function completes execution.
Dataset::Destroy, Dataset::Detach, Dataset::Dataset, Dataset::Attach
origin.h