Subject: Find name in group inside a Authors Field.
I’d suggest putting people’s names in there instead of a group.Worries with a group in there:
What if a person is inside a group which is inside a group - would the authors field still be honoured? How would you look that up ?
–
Another way is to use a UserRole in the Authors field.
Then, you can in the ACL assign the group that UserRole.
That way works quite well I have found in the past, and avoids the need to worry too much about the group inside a group problem.
–
Finally, here is some code, you can feed it a group name, it displays all the members and pops them up, and says if you are in it or not, perhaps too much for what you need but you get the idea:
Notes: the 111 number is replica id of Corporate Name and Address Book.
$Groups is a view containing groups and ordered by the group names
me:=@UserName;
t1:=@PickList([Custom]; “11111A1A:00000A0”; “($Groups)”; “Groups to select from”; “Please select a group”; 1);
t3:=@DbLookup( “Notes” : “Nocache” ; “85255F7E:006405B0”;“($Groups)”; t1 ; “Members”);
t4:=@Elements(t3);
n := 1;
@While(n <= @Elements(t3);
@For(x<t4);
storth:=@If(n=1;@Text(n)+“st”; @Text(n));
@Prompt([Ok];“The " + storth + " element is”;t3[n]);
n:=n+1);
@If(@IsMember(Me;t3);@Prompt([Ok];“Yes”;“You are a Member”);@Prompt([Ok];“No”;“You are NOT a Member”))
Hopefully you can use some of this to help you…