Click or drag to resize

RuntimeServiceUpdateGroup Method

Updates a group. Intended for web use only.

Namespace:  Advantys.Workflow.Web.Services.Processes.Runtime
Assembly:  Advantys.Workflow.Web.Services.Processes.Runtime (in Advantys.Workflow.Web.Services.Processes.Runtime.dll) Version: 7.8.0.0 (7.8.0.0)
Syntax
public void UpdateGroup(
	string groupName,
	string groupDefinition
)

Parameters

groupName
Type: SystemString
Name of the group to update
groupDefinition
Type: SystemString
Definition of the updated group as an XML string. Element names are case sensitive.
Remarks
Available since WorkflowGen version: 6.2.0

Optional Parameters.

These parameters can be used in the query string or as parameters of the Headers object in the RuntimeService class instance. See example below.

GroupId (int)Specifies the Id of the group to get. Supercedes the group name.
DirectoryName (int)Specifies the directory Name of the group to get. Can be empty if GroupId is specified or when there exists only one group with the same name in WorkflowGen.
DirectoryId (int)Specifies the directory Id of the group to get. Can be empty if GroupId is specified or when there exists only one group with the same name in WorkflowGen. Supercedes the directory name.
IgnoreMissingAssociations (bool)Sets whether or not to return an error when an association (user) is missing from the target. Default = true

Sample group definition with usernames:
<Group>
  <Name>My group</Name>
  <Description>My group's description</Description>  
  <Directory>
    <Name>WORKFLOWGEN</Name>
  </Directory>
  <Email>MyGroupEmail@WorkflowGen.com</Email>
  <LDAP_ADsPath>ADs Path</LDAP_ADsPath>
  <DistinguishedName>Distinguished name</DistinguishedName>
  <CommonName>Common name</CommonName>
  <Code>Code</Code>
  <SystemIdentifier>System identified</SystemIdentifier>
  <Synchronized>Y</Synchronized> <!-- Y, N -->
  <Users>
    <User>
      <Username>Username1</Username>
    </User>
    <User>
      <Username>Username2</Username>
    </User>
  </Users>
</Group>

Sample group definition with DataSourceQuery:
<Group>
  <Name>My group</Name>
  <Description>My group's description</Description>  
  <Directory>
    <Name>WORKFLOWGEN</Name>
  </Directory>
  <Email>MyGroupEmail@WorkflowGen.com</Email>
  <LDAP_ADsPath>ADs Path</LDAP_ADsPath>
  <DistinguishedName>Distinguished name</DistinguishedName>
  <CommonName>Common name</CommonName>
  <Code>Code</Code>
  <SystemIdentifier>System identified</SystemIdentifier>
  <Synchronized>Y</Synchronized>
  <DataSourceQuery>DEPARTMENT = 'Accounting'</DataSourceQuery>
</Group>

Sample code:
RuntimeServiceWebService.RuntimeService myRuntimeService = new RuntimeServiceWebService.RuntimeService();
RuntimeServiceWebService.GroupHeader myGroupHeader = new RuntimeServiceWebService.GroupHeader();
myRuntimeService.GroupHeaderValue = myGroupHeader;

myGroupHeader.IgnoreMissingAssociations = ignoreMissingAssociations;

myRuntimeService.UpdateGroup(groupName, groupDefinition);


See Also