RenameFormula
You can use this function for Optiva Workflows.
Purpose
The function RenameFormula assigns a new name/version to any Formula.
Syntax
object RenameFormula(string newCode, string newVersion)
Return Value
If the code is successful a value greater than zero (0) is displayed.
Arguments
| Part | Description |
|---|---|
newCode |
The new name for the formula must be provided. |
newVersion |
he new version for the formula must be provided. |
Description
RenameFormula assigns a new name and version to a formula. It replaces the name of the current formula. It is not a copy of the formula. This function refreshes on-screen data.
Examples
In this example, a new name and version number are assigned to the current workflow formula.
Dim oNewname As Object = RenameFormula ("PIZZA_SAUCE","004")
In the next example, the new formula is assigned the same name as the current formula. The version number is incremented by one.
Dim oIncrementformula As Object = RenameFormula("","+")
Example 1:The new name PIZZA_SAUCE and version 004 is assigned to current workflow formula.
RenameFormula("PIZZA_SAUCE","004");
Example 2: The formula name remains same, but the version is incremented by 1.
This example is applicable only for Version supported symbols like Formula, Specification, project etc.
RenameFormula("", "+")