A permission error is prompted when the code is used to change the business process stage.

Source: Internet
Author: User
Tags guid identifier

Error description

Seclib: accesscheckex failed. returned hR =-2147187962, objectid: 00000000-0000-0000-0000-000000000000, ownerid: 37c8e728-b05c-4b30-ac41-8ee39aa42480, owneridtype: 8 and callinguser: d2225d2c-5ae4-e711-80fd-008cfaf9d41d. objecttypecode: 2500, objectbusinessunitid: 2d99bd27-8cca-e111-8d7d-005056c00008, accessrights: createaccess where:
  • Ownerid: 37c8e728-b05c-4b30-ac41-8ee39aa42480 is a system user
Related code
VaR processinstanceid = "<process instance id>"; // businessprocessflowinstanceidvar nextstageid = "<next stage ID>"; // processstageidvar retrievedprocessinstance = service for the next stage. retrieve ("Expiration", processinstanceid, new columnset ("activestageid"); retrievedprocessinstance ["activestageid"] = new entityreference ("processstage", nextstageid); service. update (retrievedprocessinstance );

  

The trace tool traces the following logs: At versionedpluginproxystepbase. execute (pipelineexecutioncontext context) iloffset = 0x64at systemuserproxy. execute (pipelineexecutioncontext context) iloffset = 0x21at pipelineinstrumentationhelper. execute (Boolean instrumentationenabled, string stopwatchname, executewithinstrumentation action, pipelineexecutioncontext context) iloffset = 0x93at pipeline. execute (pipelineexecutioncontext context) iloffset = 0 xdeat pipelineinstrumentationhelper. execute (Boolean instrumentationenabled, string stopwatchname, executewithinstrumentation action, pipelineexecutioncontext context) iloffset = 0x35at messageprocessor. execute (pipelineexecutioncontext context) iloffset = 0x221at internalmessagedispatcher. execute (pipelineexecutioncontext context) iloffset = 0xe4at extensibleplatformmessagedispatcher. execute (pipelineexecutioncontext plugincontext) iloffset = 0x0at extensibleplatformmessagedispatcher. updatewithinvocationsource (businesstity entity, filterexpression filter, int32 invocationsource, executioncontext context) iloffset = 0x0000at extensibleplatformmessagedispatcher. update (businessEntity entity, filterexpression filter, executioncontext context) iloffset = 0 xaat businessprocessobject. updatewithpipelineandextensions (ibusinessential tity entity, executioncontext context) iloffset = 0x80at businessprocessobject. update (ibusinesstity entity, executioncontext context, Boolean updatewithpipeline) iloffset = 0x4fat runtimemethodhandle. invokemethod (object target, object [] arguments, signature Sig, Boolean constructor) iloffset = 0 xffffffffat runtimemethodinfo. unsafeinvokeinternal (Object OBJ, object [] parameters, object [] arguments) iloffset = 0x16at runtimemethodinfo. invoke (Object OBJ, bindingflags invokeattr, binder, object [] parameters, cultureinfo culture) iloffset = 0x6cat methodbase. invoke (Object OBJ, object [] parameters) iloffset = 0x0at logicalmethodinfo. invoke (object target, object [] values) iloffset = 0x64at internaloperationplugin. execute (iserviceprovider serviceprovider) iloffset = 0x43at v5pluginproxystep. executeinternal (pipelineexecutioncontext context) iloffset = 0x25dat versionedpluginproxystepbase. execute (pipelineexecutioncontext context) iloffset = 0x64at pipelineinstrumentationhelper. execute (Boolean instrumentationenabled, string stopwatchname, executewithinstrumentation action, pipelineexecutioncontext context) iloffset = 0x93at pipeline. execute (pipelineexecutioncontext context) iloffset = 0 xdeat pipelineinstrumentationhelper. execute (Boolean instrumentationenabled, string stopwatchname, executewithinstrumentation action, pipelineexecutioncontext context) iloffset = 0x35at messageprocessor. execute (pipelineexecutioncontext context) iloffset = 0x218at internalmessagedispatcher. execute (pipelineexecutioncontext context) iloffset = 0xe4at externalmessagedispatcher. executeinternal (incluservicefactory, includispatcherfactory, string messagename, string requestname, int32 primaryobjecttypecode, int32 parameters, parametercollection fields, correlationtoken values, callerorigintointoken, userauth, guid callerid, guid, usertype, guid transactioncontextid, int32 invocationsource, nullable '1 requestid, version endpointversion) iloffset = 0x22dat externalmessagedispatcher. execute (incluservicefactory, includispatcherfactory, string messagename, string requestname, int32 primaryobjecttypecode, int32 values, parametercollection fields, correlationtoken values, callerorigintointoken, userauth, guid callerid, guid identifier, usertype, guid transactioncontextid, int32 invocationsource, nullable '1 requestid) iloffset = 0x0at organizationsdkserviceinternal. principal (organizationrequest request, authentication failed, callback callerorigintoken, webservicetype servicetype, userauth, guid targetuserid, organizationcontext context, Boolean login, Boolean checkadminmode, object operation, usertype targetusertype) iloffset = 0x24aat login. executeRequest. executeRequest (organizationrequest request, correlationtoken, callerorigintointoken, webservicetype servicetype, Boolean checkadminmode, executioncontext) iloffset = 0x4bat organizationsdkserviceinternal. execute (organizationrequest request, correlationtoken, callerorigintointoken, webservicetype servicetype, Boolean checkadminmode, executioncontext) iloffset = 0x1bat organizationsdkservice. execute (organizationrequest request) iloffset = 0x6at iloffset = 0 xffffffffat syncmethodinvoker. invoke (object instance, object [] inputs, object [] & outputs) iloffset = 0x24cat dispatchoperationruntime. invokebegin (messagerpc & RPC) iloffset = 0xc4at immutabledispatchruntime. processmessage5 (messagerpc & RPC) iloffset = 0x48at messagerpc. process (Boolean isoperationcontextset) iloffset = 0x65at wrapper. resume (Boolean & alreadyresumednolock) iloffset = 0x1bat threadbehavior. resumeprocessing (iresumemessagerpc resume) iloffset = 0x8at executioncontext. runinternal (executioncontext, contextcallback callback, object state, Boolean preservesyncctx) iloffset = 0x79at executioncontext. run (executioncontext, contextcallback callback, object state, Boolean preservesyncctx) iloffset = 0x9at queueuserworkitemcallback. system. threading. ithreadpoolworkitem. executeworkitem () iloffset = 0x35at threadpoolworkqueue. dispatch () iloffset = 0xa4> Web service plug-in failed in sdkmessageprocessingstepid: {BB48066E-F22F-412F-A530-91F72E4B859B}; entityname: entity; Stage: 35; messagename: update; assemblyname: Microsoft. CRM. objectmodel. globalactivestageplugin, Microsoft. CRM. objectmodel, version = 8.0.0.0, culture = neutral, publickeytoken = 31bf3856ad364e35; classname: Microsoft. CRM. objectmodel. globalactivestageplugin; Exception: unhandled exception: Microsoft. CRM. crmsecurityexception: seclib: accesscheckex failed. returned hR =-2147187962, objectid: 00000000-0000-0000-0000-000000000000, ownerid: 37c8e728-b05c-4b30-ac41-8ee39aa42480, owneridtype: 8 and callinguser: d2225d2c-5ae4-e711-80fd-008cfaf9d41d. objecttypecode: 2500, objectbusinessunitid: 2d99bd27-8cca-e111-8d7d-005056c00008, accessrights: createaccess in Microsoft. CRM. businessentities. securitylibrary. accesscheckex2 (executioncontext context, securityprincipal principal, securityprincipal ownerprincipal, guid objectid, int32 objecttypecode, guid objectbusinessunitid, accessrights rights) in Microsoft. CRM. businessentities. securitylibrary. accesscheckex (executioncontext context, securityprincipal ownerprincipal, guid objectid, int32 objecttypecode, guid objectbusinessunitid, accessrights rights) in Microsoft. CRM. businessentities. securitylibrary. accesscheckex (executioncontext context, securityattributes attributes, accessrights rights) in Microsoft. CRM. businessentities. securityextension. precreatehandlerentityprivilegecheck (Object sender, securitytraits traits, securityattributes attributes, extensioneventargs E) in Microsoft. CRM. businessentities. securityextension. precreatesecuritycheck (Object sender, extensioneventargs E, businessEntity entity) in Microsoft. CRM. businessentities. securityextension. precreatehandler (extensioneventargs E, object sender) in Microsoft. CRM. businessentities. businessprocessobject. precreateeventhandler. invoke (Object sender, extensioneventargs E) in Microsoft. CRM. businessentities. businessprocessobject. create (ibusinesstity entity, executioncontext context, Boolean createwithpipeline) in Microsoft. CRM. platform. server. userentityuisettingsserviceadapter. upsertbyentitytypecodeanduser (int32 typecode, guid userid, string recentlyviewedxml, Dictionary '2 entitylist) in Microsoft. CRM. platform. server. userentityuisettingsserviceadapter. upsertusersettings (list '1 cliententitylist, list '1 clientviewlist, icollection '1 etclist, guid userid) in Microsoft. CRM. platform. server. userentityuisettingsserviceadapter. upsert (irecentlyviewedrecord recentlyviewedrecord, guid userid) in Microsoft. CRM. platform. server. recentlyviewedprocessservice. pinprocessfortargetentityrecord (guid processinstanceid, guid processid, ientityreference targetentity, guid userid) in Microsoft. CRM. platform. server. selectionalgorithmservice. pinprocessontargetentity (ibusinesstity processinstance, ientityreference targetentityreference, iexecutioncontext context) in Microsoft. CRM. platform. server. selectionalgorithmservice. retrievedefaprocprocessinstance (guid targetentityid, int32 targetentitytypecode, string targetentitylogicalname, Boolean moreprocessdata, iexecutioncontext executioncontext) in Microsoft. CRM. platform. server. injectprocessinstanceattributesextension. handlepostretrieve (Object sender, extensioneventargs E) in Microsoft. CRM. businessentities. businessprocessobject. postretrieveeventhandler. invoke (Object sender, extensioneventargs E) in Microsoft. CRM. businessentities. businessprocessobject. tryretrieve (businessentitymoniker moniker, entityexpression, executioncontext context, int32 languagecode, databasequerytarget querytarget, businessEntity & businessentitity) in Microsoft. CRM. businessentities. businessprocessobject. retrieve (businessentitymoniker moniker, entityexpression, executioncontext context, int32 languagecode, databasequerytarget querytarget) in Microsoft. CRM. businessentities. businessprocessobject. retrieve (businessentitymoniker moniker, entityexpression, executioncontext context, int32 languagecode) in Microsoft. CRM. businessentities. businessprocessobject. retrieve (businessentitymoniker moniker, entityexpression, executioncontext context) in Microsoft. CRM. sales. objectmodel. qoiservice. retrieve (businessentitymoniker moniker, entityexpression, executioncontext context) in Microsoft. CRM. objectmodel. businessprocessflowserviceinternalhandler '1. navigatetonextentity (ibusinessential tity bpfinstancetoupdate, guid nextentityid, string identifier, guid newactivestageid, string newtraversedpath, guid processid, executioncontext context, workflowstep) in Microsoft. CRM. objectmodel. workflowpluginhelper. navigatetonextentity (entity custombpfentity, iexecutioncontext executioncontext, ipluginexecutioncontext pluginexecutioncontext) in Microsoft. CRM. objectmodel. globalactivestageplugin. execute (iserviceprovider serviceprovider) in Microsoft. CRM. extensibility. v5pluginproxystep. executeinternal (pipelineexecutioncontext context) in Microsoft. CRM. extensibility. versionedpluginproxystepbase. execute (pipelineexecutioncontext context ). solution
  • Install patch pack, upgrade to version 8.2.2.112, CRM2016-Server-KB4046795-CHS-Amd64

 

A permission error is prompted when the code is used to change the business process stage.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.