DADiSP Worksheet Functions > Function Categories > ActiveX > Automation Server > PUTSERIES

 

PUTSERIES

Purpose:

Stores data to a Window or variable as a SafeArray to DADiSP’s ActiveX Automation Server.

Syntax:

[out] INT result = PutSeries(

[in] BSTR "name", [in] SAFEARRAY(double) data)

"name"

-

A string, the destination. Any valid Window or variable.

data

-

A SafeArray, the data to store.

Returns:

An integer, 1 if successful.

Example:

Visual Basic Example:

 

Dim DADiSP as Object

Dim VBData(1000) as Double

Dim Result() as Double

 

’’’ Create VB data array

For i = 0 To 1000

    VBData(i) = Rnd() 

Next i

 

’’’ Connect to DADiSP

Set DADiSP = CreateObject("dadisp.application")

 

’’’ Create a 2 Window Worksheet without prompting

Call DADiSP.Execute("newworksheet(2, 0)")

 

’’’ Put VB array in W1

Call DADiSP.PutSeries("W1", VBData)

 

’’’ Label W1

Call DADiSP.Execute("label(W1, 'Data from Visual Basic')")

 

’’’ get integral of W1

Call DADiSP.GetSeries("integ(W1)", Result)

 

’’’ show it

DADiSP.Visible = 1

 

 

Starts DADiSP as an ActiveX Automation server, creates a 2 Window Worksheet and places 1001 random samples from Visual Basic into W1. The Window is labeled and the SafeArray Result is a 1001x1 array containing the integration of the random data..

Remarks:

PutSeries stores real data. See PUTCOMPLEXSERIES to store complex data.

 

PutSeries explicitly stores a SafeArray. See PUTDATA to store a variant data type.

See Also:

CALCULATE

EVALUATE

EXECUTE

GETCOMPLEXDATA

GETCOMPLEXSERIES

GETFULLMATRIX

GETDATA

GETSERIES

PUTCOMPLEXDATA

PUTCOMPLEXSERIES

PUTDATA

PUTFULLMATRIX