EssVCell

Description

Retrieves one value from the server.

Syntax

EssVCell(sheetName, memberlist)
ByVal sheetName As Variant
ParamArray memberlist As Variant

Parameters

sheetName

Text name of worksheet to operate on. sheetName is of the form "[Book.xls]Sheet". If sheetName is Null or Empty, the active worksheet is used.

memberlist

A list of strings which describe the member combination for which a data value is to be retrieved. If memberlist is Null or Empty, the top level value is used.

Return Value

Returns the value of the data point if successful. Returns #N/A if the worksheet cannot be determined or is not logged in. Returns #VALUE! if a member name is incorrect.

Example

Declare Function EssVCell Lib "ESSEXCLN.XLL" (ByVal sheetName As Variant, ParamArray memberlist() As Variant) As Variant

Sub InCell()
Dim X As String
X=EssVCell("[Book2.xls]Sheet1", "Qtr1", "Actual", "Oregon")
If X = "#N/A" Then
MsgBox("Not logged in, or sheet not active.")
Else
If X = "#VALUE!" Then
MsgBox("Member name incorrect.")
Else
MsgBox(X + " Value retrieved successfully.")
End If
End If
End Sub

Note:

The value of the data point returned is not placed in a cell in the worksheet automatically. To place the value in a cell, use the Visual Basic select method and the ActiveCell property. See the Visual Basic documentation.