Retrieves data from a command, variable or Window as a string from DADiSP’s ActiveX Automation Server.
[out] BSTR result = GetCharArray(
[in] BSTR "command", [in] BSTR "workspace")
A string, a command or the name of a Window or variable.
A string, the name of the Workspace. Currently unused.
Visual Basic Example:
Dim DADiSP as Object
Dim Result1 as String
Dim Result2 as String
’’’ Connect to DADiSP
Set DADiSP = CreateObject("dadisp.application")
’’’ Create a 2 Window Worksheet without prompting
Call DADiSP.Execute("newworksheet(2, 0)")
’’’ Generate random data in W1
Call DADiSP.Execute("W1: grand(1000, 1)")
’’’ get version
Result1 = DADiSP.GetCharArray("version", "base")
’’’ get range of W1 as a string
Result2 = DADiSP.GetCharArray("max(W1) – min(W1)", "base")
’’’ show it
DADiSP.Visible = 1
Starts DADiSP as an ActiveX Automation server, creates a 2 Window Worksheet and places 1000 random samples in W1. The string Result1 contains the current version number of DADiSP. Result2 contains the range of W1 as a string.
Any DADiSP command can be executed or the contents of any Window or variable can be retrieved. The result is always converted into a string.
GetCharArray always returns a string. See GETSERIES to explicitly return a SafeArray.
See GETDATA to return a data type determined by the data.