cancel
Showing results for 
Search instead for 
Did you mean: 

Roadmap question

Former Member
0 Kudos

I have a roadmap defined with 8 steps. But depending on a result of a bapi the first step should be shown or not. I itb possible to adjust the roadmap numbering/name based on the output.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Consider you executed a BAPI and you have a result.

Bind the RoadMap UIElement "selectedStep" property to value attribute .

if( <<Some condition>>)

wdContext.currentContextElement().setSelectedStep("<<Step2>>");

else

wdContext.currentContextElement().setSelectedStep("<<Step1>>");

Step1 andStep2 should be names of the RoadMapSteps.

Regards,Anilkumar

Former Member
0 Kudos

I understand, but I forgot to mention step 1 one will be invisible and step 2 should become step 1 and get name 1 instead of 2

Former Member
0 Kudos

Hi,

I think you are complicating the solution !!!

Why do you want to change the name of the steps ?? Any concrete reason for this ??

Other way is Dynamically creating the RoadMap UIElement.Check the Dynamic progamming tutorials.

Regards,Anilkumar

Former Member
0 Kudos

request from my customer

Former Member
0 Kudos

I think you can try the following.

Bind the "Name" property of the RoadmapStep to a valueAttribute and change the value of the context dynamically the way you do for selectedStep.

Regards,Anilkumar

Former Member
0 Kudos

Hi Dresen

Bind "visible" property of each step( or just the first step in your case ) to a context attribute of type boolean. Also bind the "description" property of each steps to different context attributes of type string.

Now depending on your condition use the following code to change the steps "description" properties, and make the first step invisible. Similarly you can bind the names to context attributes and provide the values at runtime.


if(condition)  { // condition based on your bapi execution
  // set visibility of steps
   wdContext.current<SomeNode>Element.setStep0Visible(false);
   wdContext.current<SomeNode>Element.setStep1Visible(true);
   // similarly for all steps
   wdContext.current<SomeNode>Element.setStepnVisible(true);

  // set step numbers
   wdContext.current<SomeNode>Element.setStep0Description("Not_Required"); // this step is not visible anyways
   wdContext.current<SomeNode>Element.setStep1Description("Any_Desired_Step_No");
   // similarly for all steps
   wdContext.current<SomeNode>Element.setStepnDescription("Any_Desired_Step_No");
}

Regards

kk

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

You can bind the "selectedStep" property of the RoadMap UIElement to context attribute and you can change the value dynamically.

Ex :wdContext.currentContextElement().setCurrentStep("<<StepName>>");

Regards,Anilkumar

Message was edited by:

Anilkumar Vippagunta

Former Member
0 Kudos

what do you mean?