Skip to main content
Answer

How can I dynamically change a Smart Panel Caption Runtime?

  • March 8, 2022
  • 3 replies
  • 196 views

aaghaei
Captain II
Forum|alt.badge.img+10

I have a Smart Panel which is called by 4 different buttons. I was wondeing how I dynamically can change this Smart Panel Caption depending on which click button is calling it. The Smart Panel

“ID is pnlOpenDialogBox” and its “key is RoutingPanelDialog”.

I have a method to call and display this Smart Panel and do stuff with 3 parameters as follow

“private string ShowRouteDialog(string status, string title, bool finalStep)”

that I want the “title” parameter be displayed as Caption. Any though how this can be acheive? 

Best answer by Naveen Boga

Hi, @aaghaei  I don’t think we can do this graph level, hoping that it may work with Javascript code.

As an alternative, from the graph, level please find the details below.

  • Create multiple views for the same DAC each smart panel with the same design
  • Create multiple dummy views for the same DAC and provide these View names in each smart panel.
  • Use these views to invoke the smart panel at graph level, when you click on the buttons like below.
    • ViewName1.AskExt() 
    • ViewName2.AskExt() 
    • ViewName3.AskExt() 

Hope this alternative solution may help you.

 

3 replies

Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • Answer
  • March 8, 2022

Hi, @aaghaei  I don’t think we can do this graph level, hoping that it may work with Javascript code.

As an alternative, from the graph, level please find the details below.

  • Create multiple views for the same DAC each smart panel with the same design
  • Create multiple dummy views for the same DAC and provide these View names in each smart panel.
  • Use these views to invoke the smart panel at graph level, when you click on the buttons like below.
    • ViewName1.AskExt() 
    • ViewName2.AskExt() 
    • ViewName3.AskExt() 

Hope this alternative solution may help you.

 


aaghaei
Captain II
Forum|alt.badge.img+10
  • Author
  • Captain II
  • March 8, 2022

Thanks @Naveen B . Yes this is an option but is high maintenance. I have 9 screens that will be using this Smart Panel and on each screen 4 action buttons will trigger this panel resulting 36 views and panels. I was hoping to avoid doing this.


Naveen Boga
Captain II
Forum|alt.badge.img+19
  • Captain II
  • March 8, 2022

Understood @aaghaei  yes it is required high maintenance when we have many smart panels.

We might need to check with JavaScript code to achieve this.

Also, I recommend you to raise a support ticket on this to get the support quickly.