hi,
Via a calculaion, I need to check if current user is in users's group from category object.
Import System
static def GetAttributeValue(Request):
Value = false
currentuserName = Request.GetCurrentUserName().ToLower()
for grp in Request.Category._CONSGrpValFonc.UserGroups:
item = grp.User
if item.Name.ToLower() == currentuserName.ToLower() :
value = true
return Value
syntax is correct however if I test calculation I have an error message : cannot read attribute value 'UserGroups' of class type system. group
Has anyone any ideas please ?
Thanks
Regards