Searching the Help
To search for information in the Help, type a word or phrase in the Search box. When you enter a group of words, OR is inferred. You can use Boolean operators to refine your search.
Results returned are case insensitive. However, results ranking takes case into account and assigns higher scores to case matches. Therefore, a search for "cats" followed by a search for "Cats" would return the same number of Help topics, but the order in which the topics are listed would be different.
Search for | Example | Results |
---|---|---|
A single word | cat
|
Topics that contain the word "cat". You will also find its grammatical variations, such as "cats". |
A phrase. You can specify that the search results contain a specific phrase. |
"cat food" (quotation marks) |
Topics that contain the literal phrase "cat food" and all its grammatical variations. Without the quotation marks, the query is equivalent to specifying an OR operator, which finds topics with one of the individual words instead of the phrase. |
Search for | Operator | Example |
---|---|---|
Two or more words in the same topic |
|
|
Either word in a topic |
|
|
Topics that do not contain a specific word or phrase |
|
|
Topics that contain one string and do not contain another | ^ (caret) |
cat ^ mouse
|
A combination of search types | ( ) parentheses |
|
- List: JavaScript functions in the ScriptLibrary
- JavaScript function: addToGroup
- JavaScript function: checkAllowedOption
- JavaScript function: checkVersionString
- JavaScript function: isfileexist
- JavaScript function: isInGroup
- JavaScript function: removeFromGroup
- JavaScript function: returnGroupMembers
- JavaScript function: returnMyGroups
- JavaScript function: skipApproval
JavaScript function: returnGroupMembers
Returns an array containing the group members of a Configuration Management group.
Syntax
lib.ciGrouping.returnGroupMembers( groupName );
Arguments
The following arguments are valid for this function:
Name | Data type | Required | Description |
---|---|---|---|
groupName
|
String | Yes | This argument contains the name of the configuration group whose members you want to return as an array. |
Return values
An array or null.
The function returns an array containing the logical.name values of the group members if there are group members. The function returns null if it cannot find a matching group name or if the group does not have any members.
Description
This function is part of a system JavaScript and should not be directly modified.
This function returns the logical.name values of the members of a Configuration Management group.
- If the group is a list type, the function returns the array from the group configuration item record.
- If the group is a query type, the function returns an array of all the CIs it finds.
Example
This example returns the members of the group listed in the variable.
This example requires the following sample data:
- Create a list group containing one or more configuration items (for example, a list group called "test01" containing the configuration item "DEFAULT Phone 0001")
- Create a query group containing one or more configuration items (for example, a list group called "test04" containing the configuration items where type equals "telecom")
/* Create variables to store CI group name and the results of returnGroupMembers */ var targetCIGroup; var members; /* Test returnGroupMembers on a list group */ print( "Now testing returnGroupMembers on a list group...\n" ); targetCIGroup = "test01"; members = lib.ciGrouping.returnGroupMembers( targetCIGroup ); print( "The current members of " + targetCIGroup + " are:\n" + members ); /* Test returnGroupMembers on a query group */ print( "Now testing returnGroupMembers on a query group...\n" ); targetCIGroup = "test04"; members = lib.ciGrouping.returnGroupMembers( targetCIGroup ); print( "The current members of " + targetCIGroup + " are:\n" + members );
We welcome your comments!
To open the configured email client on this computer, open an email window.
Otherwise, copy the information below to a web mail client, and send this email to ovdoc-ITSM@hpe.com.
Help Topic ID:
Product:
Topic Title:
Feedback: