Click here to Skip to main content
15,899,825 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi All,

I am working on sending mail via workflow and would like for list inserts by a particular user, say
user1, to send mail to a particular AD group, say TestGroup1. Similarly, for user2 to userN.
Is it possible to determine AD group membership inside a workflow?

Thnaks in Advance,
Naresh.
Posted

Short answer is no.

SharePoint user is not the same as an AD user. Of course, SharePoint, if using Windows auth, uses AD to authenticate the Windows user and establish the claim but it creates a SPUser with no information specific to AD. Since you can have multiple authentication mechanisms and claims providers it doesn't make sense to have information specific to one in the SPUser class and it would be impractical for Microsoft, or anyone, to create objects for all possibilities.

You will need to query AD yourself.
 
Share this answer
 
Comments
NareshNemuri 22-Dec-11 4:40am    
Mr.Mark,is there any possibility of adding email Id of manager in manager's group and sending mail through workflow..so that the mail i can send to user(who adds an item in a list) and that Manager Email ID..
[no name] 22-Dec-11 8:32am    
There are a number of ways to do this. As I responded before you can use User Profile to store additional information. If the values are in AD you can query AD directly.
I have done this by adding emailId of manager in manager's group which exists in AD and sent mail through workflow..so that the mail can sent to user(who adds an item in a list) and that Manager Email ID..
 
Share this answer
 
Comments
[no name] 23-Dec-11 23:25pm    
It is very bad form to post a solution to your own question and accept it as the answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900