Skip to Content
author's profile photo Former Member
Former Member

controller_id needs to be prefixed to element id?

I found out the hard way (debugging all the details) that apparently I have to prefix the id of my listbox with the stack of controller_id's.


request = request

name = 'listbox'

id = 'c_tm_c_rl_c_rld_All_Pf' ).

where c_tm, c_rl, c_rld are the consecutive controller id's in the call stack and 'All_Pf' id the id of my ListBox element.

Is there a dynamic way to get these prefixes in stead of hardcoding them as I do now?

I just changed my app - added a controller in front - forgot to add the controller_id and my app broke down.



Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Best Answer
    Posted on Jun 09, 2005 at 10:37 AM

    Hi Erik,

    every controller has a refence to the parent controller (attribute m_parent). The parent controller has a list of his subcontrollers (attribute m_subcontrollers). So get the parent controller and use the subcontroller list to dynamically build the prefix. Btw I never build this myself but I am sure it should work that way.



    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.