CAEngine::CreateObject

Revision as of 18:18, 15 June 2015 by Karenlee (Talk | contribs) (Marked this version for translation)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

ADE User Guide > ADE Server Class Reference > CAEngine

Other languages:
English • ‎中文

CreateObject(objName,objClass)

Creates a new Analytica object with identifier «objName» and class «objClass» in the CurrentModule and returns it as a CAObject.

Parameters

objName
string - the new object's identifier
objClass
string, one of:
  • "Alias"
  • "Attribute"
  • "Button"
  • "Chance"
  • "Constant"
  • "Decision"
  • "Determ"
  • "Form"
  • "Formnode"
  • "Function"
  • "GraphStyleTemplate"
  • "Index"
  • "Library"
  • "LinkLibrary"
  • "LinkModule"
  • "Model"
  • "Module"
  • "Objective"
  • "Picture"
  • "Text"
  • "Variable"

Return value

CAObject

Example Usage

// C#
CAObject obj = ade.CreateObject ("NewVar","Chance");


API errors

  • 40 – “Object could not be created”
  • 41 – “Invalid name for object”
  • 42 – “Object name already in use”
  • 48 – “Invalid object class”
Comments


You are not allowed to post comments.