{OBJECTSPAGEGOTO} displays the Objects sheet of the active notebook. When the Objects sheet is active, you can use {SELECTOBJECT} to select icons, and other object commands to manipulate them.
You can use {SELECTBLOCK} to move from the Objects sheet to a spreadsheet sheet.
Linked {OLE.DoVerb}, {OLE.Change_Link}, {OLE.Update}, {OLE.Convert}, {OLE.Change_To_Picture}, {OLE.DisplayAsIcon}, and {OLE.ActivateAs}
Example
This macro selects an OLE object named Embedded1, lets you edit the data (in the OLE server), then converts the object into a picture (disabling the OLE link).
{SELECTFLOAT Embedded1}
{OLE.DoVerb Edit}
{OLE.Change_To_Picture}
Options
{OLE.ActivateAs ObjectType} Opens the object using a different but compatible application
{OLE.AutomaticResize 0|1} Automatically resizes the object after you edit it
{OLE.AutomaticUpdate 0|1} Turns automatic updating on or off
{OLE.Change_Link FileName} Switches links from one file to another
{OLE.Change_To_Picture} Clicks to convert the embedded picture to a differenty type
{OLE.Convert ObjectType} Converts the embedded information to a different type
{OLE.DisplayAsIcon 0|1} Displays the embedded object as an icon
{OLE.DoVerb Action} Plays, edits, or opens the object
{OLE.OpenEdit} Opens the original application to edit the object
{OLE.Update} Refreshes links to unopened files
{OnlineService}
Syntax
OnlineService(ServiceName As String, [Arguments As String])
{Optimizer} performs goal-seeking calculations and solves sets of linear and nonlinear equations and inequalities.
Constraint# refers to a constraint's order in the constraint list. Constant may be a value or a cell containing a value. The Value for Target_Value may also be a value or a cell. Use {Optimizer.Solve} after the other commands to calculate the solution.
To save an Optimizer model, use {Optimizer.Model_Cell Cell} {Optimizer.Save_Model}. To load a model, use {Optimizer.Model_Cell Cell}{Optimizer.Load_Model}
You can use {Optimizer?} or {Optimizer!} to display the Optimizer dialog box. {Optimizer?} lets the user manipulate the dialog box, whereas {Optimizer!} relies on the macro to manipulate it.
Example
The following macro sets up an Optimizer problem designed to maximize the formula in D6 by varying cells B8..B10. Seven constraints limit the solution. All options have been changed from their default settings. T2 and G13 are the upper-left cells of the report selections.
{Optimizer.Solution_cell A:D6}
{Optimizer.Solution_goal Max}
{Optimizer.Variable_cells A:B8..A:B10}
{Optimizer.Add 1,"A:D8..A:D8",<=,"1000"}
{Optimizer.Add 2,"A:B8..A:B8",>=,"100"}
{Optimizer.Add 3,"A:B9..A:B9",>=,"100"}
{Optimizer.Add 4,"A:B10..A:B10",>=,"100"}
{Optimizer.Add 5,"A:D8..A:D8",>=,"500"}
{Optimizer.Add 6,"A:D9..A:D9",<=,"900"}
{Optimizer.Add 7,"A:D10..A:D10",<=,"110000"}
{Optimizer.Max_Time 50}
{Optimizer.Max_Iters 300}
{Optimizer.Precision 5E-05}
{Optimizer.Linear 1}
{Optimizer.Show_Iters 1}
{Optimizer.Estimates Quadratic}
{Optimizer.Derivatives Central}
{Optimizer.Search Conjugate}
{Optimizer.Detail_Reporting A:T2..A:T2}
{Optimizer.Answer_Reporting A:G13..A:G13}
{Optimizer.Solve}
Options
{Optimizer.Add Constraint#, Cell, <=|>=|=|Integer, Constant} Adds a new constraint
{Optimizer.Answer_Reporting Cell} Specifies the cells for the Answer Report
{Optimizer.Auto-scale 0|1} Automatically scales variables to achieve a target value
{Optimizer.Change Constraint#, Cell, <=|>=|=|Integer, Constant} Edits the selected constraint
{Optimizer.Delete Constraint#} Removes the selected constraint
{Optimizer.Derivatives Central|Forward} Selects differencing for estimates of partial derivatives
{Optimizer.Detail_Reporting Cell} Specifies the cells for the Detail Report
{Optimizer.Estimates Quadratic|Tangent} Specifies the approach used to obtain initial estimates of the basic variables in each iteration
{Optimizer.Linear 0|1} Uses a linear method to solve the problem
{Optimizer.Load_Model} Loads cells of Optimizer settings
{Optimizer.Max_Iters Value} Sets the maximum number of iterations or trails
{Optimizer.Max_Time Value} Indicates how long Optimizer can spend looking for the best solution
{Optimizer.Model_Cell Cell} Saves cells of Optimizer settings for later use
{Optimizer.Precision Value} Controls the accuracy of the solution
{Optimizer.Reset} Clears Optimizer settings
{Optimizer.Save_Model} Saves cells of Optimizer settings for future use
{Optimizer.Search Conjugate|Newton} Selects a method for computing the search direction
{Optimizer.Show_Iters 0|1} Pauses between iterations so you can check the progress of the search
{Optimizer.Solution_Cell SolutionCell} Specifies the cell whose value you want Optimizer to measure
{Optimizer.Solution_Goal Max|Min|None|Target Value} Specifies maximum, minimum, and target values
{Optimizer.Solve} Finds a solution to the defined problem
{Optimizer.Target_Value Value} Specifies the value to be reached by the formula in the Solution Cell
{Optimizer.Tolerance Value} Indicates the maximum percentage a solution can differ from a theoretical optimum integer solution
{Optimizer.Variable_Cells Cell(s)} Specifies the cells the Optimizer can adjust to reach an optimal solution
{Order}
Syntax
{Order.Option}
PerfectScript Syntax
Order_Backward ()
Order_Forward ()
Order_ToBack ()
Order_ToFront ()
Description
{Order} reorders overlapping objects in a chart or dialog window. Each command affects selected objects in the active window.
Options
{Order.Backward} Sends the selected object back one layer
{Order.Forward} Sends the selected object forward one layer
{Order.ToBack} Sends the selected object to the back layer
{Order.ToFront} Sends the selected object to the front layer
{Outline} defines, creates, manipulates, and groups outlines.
Options
{Outline.AutoOutline} Creates an outline automatically on the current pane/page
{Outline.Group} Groups rows or columns. If the cells are not an entire row or column, whichever one contains the most elements (rows or columns) will be grouped
{Outline.Ungroup} Ungroups rows or columns. If the cells are not an entire row or column, whichever one contains the most elements (rows or columns) will be ungrouped. If the cells do not span the ENTIRE group, only those rows/columns that are inside the cells will be ungrouped
{Outline.UngroupAll} Destroys all groups on the current pane/page
{Outline.Expand} Expands a collapsed group of rows or columns. If the cells are not an entire row or column and are inside a group, whichever one contains the most elements (rows or columns) and is inside a current group, will be expanded
{Outline.Collapse} Collapses an expanded group of rows or columns. If the cells are not an entire row or column and are inside a group, whichever one contains the most elements (rows or columns) and is inside a current group will be collapsed
{Outline.Hide 0|1} Either hides or shows the outline in the current pane/page
{Outline.Summary Above|Below, Left|Right} Sets whether the summary will be above or below for row-based groups, and left or right for column-based groups
{Outline.ToLevel Rows|Columns, Level} Collapses or expands a group or rows or columns at a specific level