cancel
Showing results for 
Search instead for 
Did you mean: 

Multipleroadmapstep Problem

0 Kudos

Hi All,

I am using a Roadmap UI element.

For populating the no. of steps dynamically,I am using multipleroadmapstep UI element within the Roadmap UI element.

When I try to access the selected step through onSelect event...by accessing the context node (which is a source for multipleroadmapstep).. i get selected index as '1' always irrespective of the step i select. but if i try to access it through wdevent then i get the selected element .

So even if i set a selected step value through context attribute to highlight the selected step..it alwatys shows step '1' as a selected step.

If I try to access the selected step though 'STEP' parametrer of onSelect event then i get id for the multipleroadmapstep ui element at design time....but i need the id or name of the step and not the id of multipleroadmapstep at design time.

Thanks in advance.....

Bhushan

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi Bhushan,

The behaviour you are describing is exactly how it should be.

Just check whether the selectedStep attribute of RoadMap UI Element is bound correctly to an attribute in the context. This element should (ideally) not be a part of the node to which your MultipleRoadMapStep is bound. Just make the selectedStep independent of the dataSource for MultipleRoadMapStep.

Also, the STEP in OnSelect gives the id of MultipleRoadMapStep which is correct again. This corresponds directly to the id of the step. To get the name of the step, just bind the name to an attribute in the context and u can access it using get_attribute( ).

Regards,

Neha

0 Kudos

Hi Neha,

Thanks for ur reply...

The context attribute that is bound with 'SelectedStep' property of Roadmap UI element is in a separate node and not a part of the node that is source of data for MultipleRoadMapSteps UI element. I checked the binding part, it seems OK.

About getting the selected step 'Name' , what u suggest is correct. But with this what u get is 'Name' of the selected step and not 'ID'. So when u try to bind this 'Name' to SelectedStep property then it does not highlight the actual selected step.

So need to have some method that returns ID of the selected step and not the MultipleRoadMapStep UI element 'ID'.

Thanks .....

Bhushan

Former Member
0 Kudos

Hi Bhushan,

In one of my components, I have a roadmap with multiple dynamic steps. In that, the node that acts as a dataSource for the MultipleRoadMapStep element has several elements that correspond one-to-one to the steps in the roadmap. Here in I have a an attribute (type I) called STEPID which I maintain myself (while populating the context node). This has the same value as 'Name' property(Name is wht gets displayed in the box in the step, description gets displayed below the step).

Now, the highlighted step is simply decided by binding the selectedStep property of the RoadMap to a context attribute that contains the selected step in the onSelect event.

call method wd_context->set_attribute

exporting

value = step "comes from import parameters of OnSelect action handler

name = 'SELECTED_STEP' .

Regards,

Neha

0 Kudos

Hi Neha..

Thanks...

The problem is still not resolved....So just need few answers ..

1. When we create the onSelect action ,is STEP parameter already there in the parameter list or do we need to add it ?

In my case i didn't see it so added it after i created the action .

2.When on onSelect action handler (When a particular step is selected), what value do you get for STEP? Is it the selected step id (that u maintained)?

In my case as i mentioned in the previous post i get the ID of the multipleroadmapstep ui element (ID on layout) .

Thanks & Regards,

Bhushan

former_member215843
Active Participant
0 Kudos

Hi Bhushan,

Just declare the parameter "CONTEXT_ELEMENT" type ref to IF_WD_CONTEXT_ELEMENT in your action handler. On select this is the reference to the context element with the data for the current step. Just get the information you need from there.

Regina

0 Kudos

Hi Regina,

what you suggest is right. By accessing wdevent, we can have the selected element or step. But when I pass name or Id of this step to SelectedStep property of Roadmap UI element (by setting context attribute), the current selected step does not get highlighted.

Thanks & Regards,

Bhushan Kale

former_member215843
Active Participant
0 Kudos

You have to set the lead-selection to the element, which corresponds to the step to be highlighted.

Regina

Former Member
0 Kudos

Hi Regina,

Could you explain me how can I change the lead_selection_index of the conext_node?, because when I call the set_lead_selection_index method i get a dump saying that the index value (2) that i passed is not valid.

¿What am I doing wrong?.

Regards,

Eric