Do anyone know RP.getListControl().getLabel()

ganesh68
Kilo Contributor
RP.getListControl().getLabel()

Do anyone know how this works?

11 REPLIES 11

MrMuhammad
Giga Sage

Hi,

I believe, RP.getListControl() is used to access the properties of list controls. getLabel() function will help you get the list label which is defined as a value of the label field on the List Control page. 

You can see list controls properties by right-clicking the column header in the related list and selecting configure > list control. The red box contains the properties for the incident list.

find_real_file.png

Please note this will only work for related lists. 

Regards,

Muhammad

Regards,
Muhammad

Hi Muhammad,

I have tried using RP.getListControl().getLabel() , its always evaluating to true. DO you know the reason.

That is possible as the Label for list control is always static. I hope you are testing this for the related list. Can you share the code where you are using this for comparison? 

For validation, you can right-click on the related list column header and select configure -> List Control and see what value is there in the "Label" column. That will help you understand if the code should return you true or not. 

Just FYI on the usage, OOB There is a "New" Ui action which has condition something like below

"Agent Capacities".equals(RP.getListControl().getLabel())

Above is comparing "Agent Capacities" to List Control <Label field value>. 

Regards,
Muhammad

"Agent Capacities".equals(RP.getListControl().getLabel())

 

I have used this to my RL , even also button is visible

Can you please explain what exactly you are trying to achieve and if you can possibly share your UI action condition that will help us provide to the point solution? 

Regards,
Muhammad