## 3.14.2  SAPCallMemberSelector
With this API method, you can call the standard input help (member selector) from the worksheet. The standard input help is the dialog that is used for filtering in Analysis. If you define the ReferenceCell parameter, the inplace selector is called. The inplace selector is a smaller version of the member selector. You can use it to select members of a dimension, but you cannot change how members are displayed in the selector, for example to change the display from key to text.
To call the method, use Application.Run and specify the following input parameters:
## · Formula Alias
Enter the formula alias for the data source or planning object. You can set the alias when configuring the data source on the Components tab in the design panel.
You have to define this parameter if the variables in the workbook are not merged. If the variables in the workbook are merged, you can define this parameter but you do not have to define it.
## · Selector Type
Enter one of the following selector types:
- PROMPT to get a selector with the prompt members.
- FILTER to get a selector with the dimension members.
- FILTER\_MASTERDATA to get a selector with all members of the master data for the selected dimension.
- PLAN\_PARAMETER to get a selector with the members of a variable (filled and unfilled) of a planning object.
- FILTER\_NEW\_LINES to get a selector with member access mode P (Planning) in leaf member view. Leaf members are members that do not have any child members.
- FILTER\_NEW\_LINES\_WITH\_MASTER\_DATA to get a selector with all members of the master data for the selected dimension in leaf members view. Leaf members are members that do not have any child members.
## · Name
Enter the name of the variable or dimension.
- ReferenceCell Define the cell in which the inplace selector is displayed. This parameter is optional.
## · Selection Type
Enter one of the following selection types:
- SINGLE
With this selection type, you can select only one member for filtering.
- MULTIPLE With this selection type, you can select multiple members for filtering.
- MULTIPLEBYRANGE
With this selection type, you can select a range of members for filtering.
This parameter is optional.
The system returns one of the following output parameters for each function execution:
- InputString = selected data.
- Error = if invalid data is selected.
- False = if the dialog is canceled.
## Example: SAPCallMemberSelector Filter
## Dim lResult As Variant
lResult= Application.Run("SAPCallMemberSelector", "DS\_1", "FILTER", "0MATERIAL")
The member selector for dimension 0MATERIAL is displayed, and you can select the members you need. You can also select a range of members or change how the members are displayed in the selector.
## Example: SAPCallMemberSelector Filter used for SAPSetFilter
```
Public Sub CallMemberSelectorFilter() Dim lResult As Variant lResult = Application.Run("SAPCallMemberSelector", "DS_1", "FILTER", "0MATERIAL") If Not IsError(lResult) Then If lResult <> False Then Call Application.Run("SAPSetFilter", "DS_1", "0MATERIAL",lResult) End If End If End Sub
```
The member selector for dimension 0MATERIAL is displayed, and you can select the members you need. If the selected data is valid and the dialog is not canceled, the filter for dimension 0MATERIAL is set to the selected members.
## Example: SAPCallMemberSelector Inplace
## Dim lResult As Variant
lResult= Application.Run("SAPCallMemberSelector", "DS\_1", "FILTER", "0MATERIAL", ActiveCell)
The inplace selector for dimension 0MATERIAL is displayed in the active cell, and you can select the members you need.
## Example: SAPCallMemberSelector Inplace with single selection
Dim lResult As Variant lResult= Application.Run("SAPCallMemberSelector", "DS\_1", "FILTER", "0MATERIAL", ActiveCell, "SINGLE")
The inplace selector for dimension 0MATERIAL is displayed in single selection mode in the active cell, and you can select the member you need.
## Related Information
SAPSetFilter [page 117]