how to check the user is active or deactivated
Discussion posts and replies are publicly visible
Go to admin console and navigate to users page and on the top there will be radio buttons to check active and inactiveIn the search bar type the user you want to check if not there in active list check in inactive list
if you want to make inactive acc to active by selecting the user
sorry
the scenario is am sending email to group before sending an email to group i have to check whether all users are active or not, if i include deactivated users the process module will fail in production. so need to remove the deactivated users
Are you sure that sending an email to a group that contains a deactivated user is a problem?
What exactly are you doing here?
yes, sending an email to a group that might contains a deactivated user in production
I just did a quick test and did not see any issue. There must be something special with your setup.
there must be at least one user valid then it works. KM check if you are getting "No valid recipients" error, you need to handle that condition.
Hey KM ,
One approach to verify the active status of all users is by examining the user record. There's a boolean field labeled "active" that indicates whether a user is currently active. By filtering users based on this field, you can retrieve a list of all active users and subsequently send them emails.
KM said:before sending an email to group i have to check whether all users are active or not, if i include deactivated users the process module will fail
I don't believe this is the way it works when you use a group as the target for Send Email. AFAIK deactivated users don't show up in their former group(s) at all, for normal usage like this.
Confirming the remarks by Mike Schmitt.If a user gets deactivated then the user gets removed all of its group memberships.So it will not be possible to send an email to an inactive user based on a group membership.BTW - If a user gets reactivated - all its former group memberships are getting reinstated.
correct, just need to check a!isNullOrEmpty( a!groupMembers(cons!XXXGRP).data) to skip node.
Anna P said:correct, just need to check a!isNullOrEmpty( a!groupMembers(cons!XXXGRP).data) to skip node
Yes, though if it helps, this is only needed if the email has no other valid recipients (i.e. including hardcoded recipients and/or other groups that may not be empty; including anywhere in the TO, CC and BCC boxes).