API Interface


OptiY disposes of complex COM-objects for Application Programming Interface (API). Within, user can access intern structure or date of the experiment. to start a new OptiY or to embed to the started program OptiY, following code is required in VBA, VBScript or Visual Basic:

                Set OptiY = CreateObject("OptiY.Application")

With introducing of .Net Framework, the calling command has changed significantly. For .Net languages, the code must be followed:

                Dim OptiY = Activator.CreateInstance(Type.GetTypeFromProgID("OptiY.Application"))

For the .Net Framework, OptiY makes an interoperability assembly "OptiY.Interop.dll" available in the system directory. Using .Net programming language as Visual Basic or C#, user can add it to the reference and start OptiY with following code:

                Dim OptiY As Object = New OptiY.Interop.Application

For the intern scripting of OptiY with the Script Editor, the variable OptiY is already defined and can be used without any definition. For extern scripting or programming, e.g. with Visual Studio Express Edition, user has first to define this variable OptiY as above explicitly. The variable OptiY references on the COM-object Application and can be used to access further other COM objects. The COM interface of OptiY contains following objects: