LoadFormulaDlg

<< Click to Display Table of Contents >>

 

LoadFormulaDlg

LoadFormulaDlg(FormulaName, [UnitName], [ValueName])

This method opens a dialog box that displays Units and Value Sets configured on a Formula (FormulaName), allowing users to select a Value Set and the Unit to which this Set is loaded.

The optional parameters UnitName and ValueName are variables that receive, respectively, the name of the Unit and the name of the Value Set loaded to the Formula. The dialog box on the next figure is displayed as a result of calling this method on the example code that follows. This method returns a Boolean value indicating whether it was successfully executed or not.

Dialog box of LoadFormulaDlg method

Dialog box of LoadFormulaDlg method

Sub Button1_Click()
  FormulaName = "Formula1"
  If Application.LoadFormulaDlg(FormulaName, UnitName, ValueSet) Then
    MsgBox "The Value Set " & ValueSet & " was loaded to Unit " & UnitName
  Else
    MsgBox "Error when loading Formula " & FormulaName
  End If
End Sub

Was this page useful?