ObjectExists

You can use this function for Optiva Workflows and Copy Methods.

Purpose

Checks for the existence of an object key for a symbol.

Syntax


Dim variable As Integer = ObjectExists(Object,Symbol)

Arguments

Part Description
Object Object to check for existence. Use empty quotation marks for the current object, for the workflow, or the new object for the copy method.
Symbol Type of object. Use empty quotation marks for the current symbol for the workflow, or the new object for the copy method.

Description

ObjectExists determines if an object key exists for a symbol. You can use ObjectExists to check if an object key, such as a particular formula or item, already exists.

  • If the object does not exist, then a value of 0 is returned.
  • If an object does exist, then a value of 1 is returned.

Examples

In these examples, ObjectExists determines if the formula or item with the specified key exists. For formulas and specifications, you must include a backslash (\) followed by a version number.


Dim iExists As Integer = ObjectExists("PIZZASAUCE\003", "FORMULA")
iExists = ObjectExists("OLIVE_OIL","ITEM")