Check users access in Workflowdocument class
Get List of user doesn't have proper access for class-SysWorkflowDocument
Create New class
public static server void main(Args _args)
{
container result, args;
UserInfo UserInfo;
while select id from UserInfo
{
try
{
new RunAsPermission(UserInfo.id).assert();
result = runAs(UserInfo.id, classNum(SysWorkflowDocument), staticMethodStr(SysWorkflowDocument, assertAsUser), args);
CodeAccessPermission::revertAssert();
}
catch
{
CodeAccessPermission::revertAssert();
info(UserInfo.id);
}
}
}
Get List of user doesn't have proper access for class-SysWorkflowDocument
Create New class
public static server void main(Args _args)
{
container result, args;
UserInfo UserInfo;
while select id from UserInfo
{
try
{
new RunAsPermission(UserInfo.id).assert();
result = runAs(UserInfo.id, classNum(SysWorkflowDocument), staticMethodStr(SysWorkflowDocument, assertAsUser), args);
CodeAccessPermission::revertAssert();
}
catch
{
CodeAccessPermission::revertAssert();
info(UserInfo.id);
}
}
}
No comments:
Post a Comment