Skip to Content
author's profile photo
Former Member

Retrieving HTML elements' ids in Java

Add comment
10|10000 characters needed characters exceeded

  • Follow
  • Get RSS Feed

1 Answer

  • author's profile photo
    Former Member
    Feb 17, 2004 at 03:16 PM

    Hi,

    I'm facing a problem when trying to retrieve an HTML element id in my DynPage, for use in JavaScript.

    I've tried to call  getPageContext().getParamIdForComponent(component) method inside the "doProcessBeforeOutput()" method, but kept receiving the following Jave Runtime Excpetion message:

    "Component ... not found in old form"

    After inspecting the matter, I found out that the method returned the id of the HTML input in the old form, the one that had submitted itself and called this IView's instance.

    Instead, I would like to receive the FUTURE id of the HTML input that is to be put in the form which is built in "doProcessBeforOutput()" method.

    Any ideas?

    I know that calling the method in JSP from the context DOES work.

    How does it work in JAVA?

    thanks in advance .

    Add comment
    10|10000 characters needed characters exceeded

    • Former Member Former Member

      Thank you Vivek,

      BUT as I wrote, I KNOW that this works for JSP (I tried it myself).

      However, the difficulties arise when I use HTMLB in a JAVA DynPage (not JSP).

      still any ideas?

      thanks.