Hello everybody!
I've a dude with the function: Xrm.Page.data.process.moveNext(); ..... It can be use for move to a specific stage? for example:
Stage 1: Identification
Stage 2: Development
Stage 3: Solution
Stage 4: Implementation
Stage 5: Lost Client
Stage 6: Hold On
I can use moveNext() to move by the process (1-2-3-4) , but I want make that if in Stage (1-2-3) the client abandoned the proyect, so we must move to Stage 5. In another case, if in Stage (1-2-3) the client/we get a unspected problem and can't keep with the proyect for the moment, so we must move to Stage 6 until we can be able to retunt to the last Stage before Stage 6: Hold On.
For your time "Thanks You!" and sorry for my english.
*This post is locked for comments
Hello there.
I've a dude, how I can know all Stages Id? Because in option (1) I supposed that I must know it first for write there... and I've read aboud callbackFunction but I don't undestard it, it's a function? (need write any value here or it's a default string?).
If you can, you will make a little example? I'm very new in JavaScript.
For your time thanks you.
Hi there.
MoveNext() only set the next stage.
But you can achieve your goal with the following code:
1. If you know your stages, set them using the following method in JS on your conditional checkpoints
Xrm.Page.data.process.setActiveStage(stageId, callbackFunction);
2.Or using the addOnStageSelected method to add your own handler & call the following method to call the subroutine till the needed stage is attained
Xrm.Page.data.process.addOnStageSelected(handler);
Mohamed Amine Mahmoudi
83
Super User 2025 Season 1
Community Member
54
Victor Onyebuchi
6