Adf inputDate Problem

hello oracles ;
i m using adf BC to create some JSPX pages in jdev 11.
i have a form wich have a dateInput, wich allows to select the date and show it it the field .but i want to save this date to the data base with the time of the operation when it was occured too !
but here i get just the date.
how can i save with the date the the time of the operation . like this : "dd/mm/yyyy hh:mm:ss"
thanks, regards ;

You just want to save the time, or do you want the user to enter the time as well??
Select your <af:inputDate in the structure window. Right click and say Insert Inside->ADF Faces->Convert Date Time. Here you can set the pattern till hh:mm:ss ...
If you want to automatically append the current time, at the time of insertion, you can override your doDML operation. You can write your custom code in the pre-insert section..
http://radio.weblogs.com/0118231/2003/07/28.html
Julian

Similar Messages

  • Alternative to ADF InputDate

    Hi Guys,
    We are facing some frustration with adf inputDate. We need to change it to show Monday as first day of week (currently is sunday) and also, we want to implement something like clicking on the field instead clicking on the icon to show the datePicker.
    We are trying to use JQuery but there is a lot of work in order to process all the custom validations, etc.
    What would you recommend? Can we accomplish this requirements by using the original adf inputDate?
    Regards,
    P.S JDeveloper 11.1.1.6

    Hi Alejandro,
    Check the solution provided in this discussion (last entry): af:inputDate on focus/cursor
    (this is only for show the date picker on focus event)
    AP
    Update:
    To change first day of week check this out (I tested it and works like a charm): http://soadev.blogspot.com.es/2010/03/change-global-date-format-of-your.html

  • ADF Tutorial: problem with chapter 10 (Deploying the Application)

    Hi!
    I'm learning from ADF Tutorial (http://www.oracle.com/technology/obe/ADFBC_tutorial_1013/index.htm) and I have problem with chapter 10. After deploying finished application on the server (OracleAS10g) I try to test it but I get this error everytime:
    500 Internal Server Error
    Servlet error: An exception occured. The current application deployment descriptors do not allow for including it in this response. Please consult the application log for details.
    I get this error after typing login credentials. I didn't consult the log, because I don't know where to look for it (could you tell me please?). I did everything as described in the Tutorial, but I know there are mistakes (in Tutorial), so I don't know what to do.
    Thanks for any advices.

    Hi,
    I'm running Windows XP, JDeveloper version 10.1.3.4.0, Oracle AS 10g version 10.1.3.4.0 with patch. When I tried to deploy same application on Windows Vista and OC4J, it work perfectly, which really confuses me. I think I found log file so I will post it here. It's long, I'm sorry about that:
    09/01/23 16:07:07.62 SRTutorial: Servlet error
    JBO-30003: Fond aplikace (oracle.srtutorial.datamodel.SRPublicServiceLocal) selhal při odhlášení modulu aplikace z důvodu následující výjimky:
    oracle.jbo.JboException: JBO-29000: JBO-29000: Bad version number in .class file
         Neplatná třída: oracle.srtutorial.datamodel.SRPublicServiceImpl
         Zavaděč: SRTutorial.web.SRTutorial:0.0.0
         Code-Source: /C:/OracleAS/j2ee/home/applications/SRTutorial/SRTutorial/WEB-INF/classes/
         Konfigurace: WEB-INF/classes/ in C:\OracleAS\j2ee\home\applications\SRTutorial\SRTutorial\WEB-INF\classes
         Závislá třída: oracle.jbo.common.java2.JDK2ClassLoader
         Zavaděč: adf.oracle.domain:10.1.3.1
         Code-Source: /C:/OracleAS/BC4J/lib/adfm.jar
         Konfigurace: <code-source> in /C:/OracleAS/j2ee/home/config/server.xml
         at oracle.jbo.common.ampool.ApplicationPoolImpl.doCheckout(ApplicationPoolImpl.java:2002)
         at oracle.jbo.common.ampool.ApplicationPoolImpl.useApplicationModule(ApplicationPoolImpl.java:2793)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:453)
         at oracle.jbo.http.HttpSessionCookieImpl.useApplicationModule(HttpSessionCookieImpl.java:233)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:424)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:419)
         at oracle.adf.model.bc4j.DCJboDataControl.rebuildApplicationModule(DCJboDataControl.java:1517)
         at oracle.adf.model.bc4j.DCJboDataControl.beginRequest(DCJboDataControl.java:1381)
         at oracle.adf.model.binding.DCDataControlReference.getDataControl(DCDataControlReference.java:99)
         at oracle.adf.model.BindingContext.get(BindingContext.java:457)
         at oracle.adf.model.binding.DCUtil.findSpelObject(DCUtil.java:280)
         at oracle.adf.model.binding.DCUtil.findSpelObject(DCUtil.java:248)
         at oracle.adf.model.binding.DCUtil.findContextObject(DCUtil.java:383)
         at oracle.adf.model.binding.DCIteratorBinding.<init>(DCIteratorBinding.java:127)
         at oracle.jbo.uicli.binding.JUIteratorBinding.<init>(JUIteratorBinding.java:60)
         at oracle.jbo.uicli.binding.JUIteratorDef.createIterBinding(JUIteratorDef.java:87)
         at oracle.jbo.uicli.binding.JUIteratorDef.createIterBinding(JUIteratorDef.java:51)
         at oracle.adf.model.binding.DCIteratorBindingDef.createExecutableBinding(DCIteratorBindingDef.java:277)
         at oracle.adf.model.binding.DCBindingContainerDef.createExecutables(DCBindingContainerDef.java:296)
         at oracle.adf.model.binding.DCBindingContainerDef.createBindingContainer(DCBindingContainerDef.java:425)
         at oracle.adf.model.binding.DCBindingContainerReference.createBindingContainer(DCBindingContainerReference.java:54)
         at oracle.adf.model.binding.DCBindingContainerReference.getBindingContainer(DCBindingContainerReference.java:44)
         at oracle.adf.model.BindingContext.get(BindingContext.java:483)
         at oracle.adf.model.BindingContext.findBindingContainer(BindingContext.java:313)
         at oracle.adf.model.BindingContext.findBindingContainerByPath(BindingContext.java:633)
         at oracle.adf.model.BindingRequestHandler.isPageViewable(BindingRequestHandler.java:268)
         at oracle.adf.model.BindingRequestHandler.beginRequest(BindingRequestHandler.java:169)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:161)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:871)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:453)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:221)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:122)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:111)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)
    ## Detail 0 ##
    oracle.jbo.JboException: JBO-29000: Bad version number in .class file
         Neplatná třída: oracle.srtutorial.datamodel.SRPublicServiceImpl
         Zavaděč: SRTutorial.web.SRTutorial:0.0.0
         Code-Source: /C:/OracleAS/j2ee/home/applications/SRTutorial/SRTutorial/WEB-INF/classes/
         Konfigurace: WEB-INF/classes/ in C:\OracleAS\j2ee\home\applications\SRTutorial\SRTutorial\WEB-INF\classes
         Závislá třída: oracle.jbo.common.java2.JDK2ClassLoader
         Zavaděč: adf.oracle.domain:10.1.3.1
         Code-Source: /C:/OracleAS/BC4J/lib/adfm.jar
         Konfigurace: <code-source> in /C:/OracleAS/j2ee/home/config/server.xml
         at oracle.jbo.pool.ResourcePool.createResource(ResourcePool.java:545)
         at oracle.jbo.common.ampool.ApplicationPoolImpl.prepareApplicationModule(ApplicationPoolImpl.java:2094)
         at oracle.jbo.common.ampool.ApplicationPoolImpl.doCheckout(ApplicationPoolImpl.java:1961)
         at oracle.jbo.common.ampool.ApplicationPoolImpl.useApplicationModule(ApplicationPoolImpl.java:2793)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:453)
         at oracle.jbo.http.HttpSessionCookieImpl.useApplicationModule(HttpSessionCookieImpl.java:233)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:424)
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule(SessionCookieImpl.java:419)
         at oracle.adf.model.bc4j.DCJboDataControl.rebuildApplicationModule(DCJboDataControl.java:1517)
         at oracle.adf.model.bc4j.DCJboDataControl.beginRequest(DCJboDataControl.java:1381)
         at oracle.adf.model.binding.DCDataControlReference.getDataControl(DCDataControlReference.java:99)
         at oracle.adf.model.BindingContext.get(BindingContext.java:457)
         at oracle.adf.model.binding.DCUtil.findSpelObject(DCUtil.java:280)
         at oracle.adf.model.binding.DCUtil.findSpelObject(DCUtil.java:248)
         at oracle.adf.model.binding.DCUtil.findContextObject(DCUtil.java:383)
         at oracle.adf.model.binding.DCIteratorBinding.<init>(DCIteratorBinding.java:127)
         at oracle.jbo.uicli.binding.JUIteratorBinding.<init>(JUIteratorBinding.java:60)
         at oracle.jbo.uicli.binding.JUIteratorDef.createIterBinding(JUIteratorDef.java:87)
         at oracle.jbo.uicli.binding.JUIteratorDef.createIterBinding(JUIteratorDef.java:51)
         at oracle.adf.model.binding.DCIteratorBindingDef.createExecutableBinding(DCIteratorBindingDef.java:277)
         at oracle.adf.model.binding.DCBindingContainerDef.createExecutables(DCBindingContainerDef.java:296)
         at oracle.adf.model.binding.DCBindingContainerDef.createBindingContainer(DCBindingContainerDef.java:425)
         at oracle.adf.model.binding.DCBindingContainerReference.createBindingContainer(DCBindingContainerReference.java:54)
         at oracle.adf.model.binding.DCBindingContainerReference.getBindingContainer(DCBindingContainerReference.java:44)
         at oracle.adf.model.BindingContext.get(BindingContext.java:483)
         at oracle.adf.model.BindingContext.findBindingContainer(BindingContext.java:313)
         at oracle.adf.model.BindingContext.findBindingContainerByPath(BindingContext.java:633)
         at oracle.adf.model.BindingRequestHandler.isPageViewable(BindingRequestHandler.java:268)
         at oracle.adf.model.BindingRequestHandler.beginRequest(BindingRequestHandler.java:169)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:161)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:621)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:370)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:871)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:453)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:221)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:122)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.run(HttpRequestHandler.java:111)
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
         at java.lang.Thread.run(Thread.java:595)
    ## Detail 0 ##
    oracle.classloader.util.AnnotatedClassFormatError: Bad version number in .class file
         Neplatná třída: oracle.srtutorial.datamodel.SRPublicServiceImpl
         Zavaděč: SRTutorial.web.SRTutorial:0.0.0
         Code-Source: /C:/OracleAS/j2ee/home/applications/SRTutorial/SRTutorial/WEB-INF/classes/
         Konfigurace: WEB-INF/classes/ in C:\OracleAS\j2ee\home\applications\SRTutorial\SRTutorial\WEB-INF\classes
         Závislá třída: oracle.jbo.common.java2.JDK2ClassLoader
         Zavaděč: adf.oracle.domain:10.1.3.1
         Code-Source: /C:/OracleAS/BC4J/lib/adfm.jar
         Konfigurace: <code-source> in /C:/OracleAS/j2ee/home/config/server.xml
         at oracle.classloader.PolicyClassLoader.findLocalClass (PolicyClassLoader.java:1462) [C:/OracleAS/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@12700959]
         at oracle.classloader.SearchPolicy$FindLocal.getClass (SearchPolicy.java:167) [C:/OracleAS/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@12700959]
         at oracle.classloader.SearchSequence.getClass (SearchSequence.java:119) [C:/OracleAS/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@12700959]
         at oracle.classloader.PolicyClassLoader.internalLoadClass (PolicyClassLoader.java:1674) [C:/OracleAS/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@12700959]
         at oracle.classloader.PolicyClassLoader.loadClass (PolicyClassLoader.java:1635) [C:/OracleAS/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@12700959]
         at oracle.classloader.PolicyClassLoader.loadClass (PolicyClassLoader.java:1620) [C:/OracleAS/j2ee/home/lib/pcl.jar (from system property java.class.path), by sun.misc.Launcher$AppClassLoader@12700959]
         at java.lang.ClassLoader.loadClassInternal (ClassLoader.java:319) [jre bootstrap, by jre.bootstrap:1.5.0_06]
         at java.lang.Class.forName0 (Native method) [unknown, by unknown]
         at java.lang.Class.forName (Class.java:242) [jre bootstrap, by jre.bootstrap:1.5.0_06]
         at oracle.jbo.common.java2.JDK2ClassLoader.loadClassForName (JDK2ClassLoader.java:38) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.JBOClass.forName (JBOClass.java:164) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.JBOClass.findCustomClass (JBOClass.java:177) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.server.ApplicationModuleDefImpl.loadFromXML (ApplicationModuleDefImpl.java:836) [C:/OracleAS/BC4J/lib/bc4jmt.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.server.ApplicationModuleDefImpl.loadFromXML (ApplicationModuleDefImpl.java:770) [C:/OracleAS/BC4J/lib/bc4jmt.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.server.MetaObjectManager.loadFromXML (MetaObjectManager.java:534) [C:/OracleAS/BC4J/lib/bc4jmt.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.mom.DefinitionManager.loadLazyDefinitionObject (DefinitionManager.java:579) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.mom.DefinitionManager.findDefinitionObject (DefinitionManager.java:441) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.mom.DefinitionManager.findDefinitionObject (DefinitionManager.java:374) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.mom.DefinitionManager.findDefinitionObject (DefinitionManager.java:356) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.server.MetaObjectManager.findMetaObject (MetaObjectManager.java:700) [C:/OracleAS/BC4J/lib/bc4jmt.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.server.ApplicationModuleDefImpl.findDefObject (ApplicationModuleDefImpl.java:232) [C:/OracleAS/BC4J/lib/bc4jmt.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.server.ApplicationModuleImpl.createRootApplicationModule (ApplicationModuleImpl.java:401) [C:/OracleAS/BC4J/lib/bc4jmt.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.server.ApplicationModuleHomeImpl.create (ApplicationModuleHomeImpl.java:91) [C:/OracleAS/BC4J/lib/bc4jmt.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.DefaultConnectionStrategy.createApplicationModule (DefaultConnectionStrategy.java:139) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.DefaultConnectionStrategy.createApplicationModule (DefaultConnectionStrategy.java:80) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.ApplicationPoolImpl.instantiateResource (ApplicationPoolImpl.java:2468) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.pool.ResourcePool.createResource (ResourcePool.java:536) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.ApplicationPoolImpl.prepareApplicationModule (ApplicationPoolImpl.java:2094) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.ApplicationPoolImpl.doCheckout (ApplicationPoolImpl.java:1961) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.ApplicationPoolImpl.useApplicationModule (ApplicationPoolImpl.java:2793) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule (SessionCookieImpl.java:453) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.http.HttpSessionCookieImpl.useApplicationModule (HttpSessionCookieImpl.java:233) [C:/OracleAS/BC4J/lib/adfmweb.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule (SessionCookieImpl.java:424) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.common.ampool.SessionCookieImpl.useApplicationModule (SessionCookieImpl.java:419) [C:/OracleAS/BC4J/lib/bc4jct.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.bc4j.DCJboDataControl.rebuildApplicationModule (DCJboDataControl.java:1517) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.bc4j.DCJboDataControl.beginRequest (DCJboDataControl.java:1381) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCDataControlReference.getDataControl (DCDataControlReference.java:99) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.BindingContext.get (BindingContext.java:457) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCUtil.findSpelObject (DCUtil.java:280) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCUtil.findSpelObject (DCUtil.java:248) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCUtil.findContextObject (DCUtil.java:383) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCIteratorBinding.<init> (DCIteratorBinding.java:127) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.uicli.binding.JUIteratorBinding.<init> (JUIteratorBinding.java:60) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.uicli.binding.JUIteratorDef.createIterBinding (JUIteratorDef.java:87) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.jbo.uicli.binding.JUIteratorDef.createIterBinding (JUIteratorDef.java:51) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCIteratorBindingDef.createExecutableBinding (DCIteratorBindingDef.java:277) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCBindingContainerDef.createExecutables (DCBindingContainerDef.java:296) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCBindingContainerDef.createBindingContainer (DCBindingContainerDef.java:425) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCBindingContainerReference.createBindingContainer (DCBindingContainerReference.java:54) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.binding.DCBindingContainerReference.getBindingContainer (DCBindingContainerReference.java:44) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.BindingContext.get (BindingContext.java:483) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.BindingContext.findBindingContainer (BindingContext.java:313) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.BindingContext.findBindingContainerByPath (BindingContext.java:633) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.BindingRequestHandler.isPageViewable (BindingRequestHandler.java:268) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.BindingRequestHandler.beginRequest (BindingRequestHandler.java:169) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter (ADFBindingFilter.java:161) [C:/OracleAS/BC4J/lib/adfm.jar (from <code-source> in /C:/OracleAS/j2ee/home/config/server.xml), by adf.oracle.domain:10.1.3.1]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.ServletRequestDispatcher.invoke (ServletRequestDispatcher.java:621) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.ServletRequestDispatcher.forwardInternal (ServletRequestDispatcher.java:370) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.doProcessRequest (HttpRequestHandler.java:871) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.processRequest (HttpRequestHandler.java:453) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.serveOneRequest (HttpRequestHandler.java:221) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.run (HttpRequestHandler.java:122) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].server.http.HttpRequestHandler.run (HttpRequestHandler.java:111) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run (ServerSocketReadHandler.java:260) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at com.evermind[Oracle Containers for J2EE 10g (10.1.3.4.0) ].util.ReleasableResourcePooledExecutor$MyWorker.run (ReleasableResourcePooledExecutor.java:303) [C:/OracleAS/j2ee/home/lib/oc4j-internal.jar (from <code-source> in META-INF/boot.xml in C:\OracleAS\j2ee\home\oc4j.jar), by oc4j:10.1.3]
         at java.lang.Thread.run (Thread.java:595) [jre bootstrap, by jre.bootstrap:1.5.0_06]

  • ADF Javascript problem: cannot get id of an component

    hi, am currently reading and executing examples from ADF faces Web UI Developers Guide for jdeveloper 11g.
    i am trying to execute example 3-7
    I have a <af:commandButton> component , whose id i want to display in an alert box.
    However i am unable to display it
    here is the sample code i made up:
    <f:view>
    <af:document title="hello from component" >
    <af:form >
    <af:commandButton text="show id" id="cmdbutton">
    <af:clientListener method="sayHello" type="action"/>
    </af:commandButton>
    </af:form>
    <f:facet name="metaContainer">
    <trh:script>
    <f:verbatim>
    function sayHello(actionEvent)
    var component= actionEvent.getSource();
    //Get the ID for the component
    var id = component.getId ;
    alert("Hello from " + id);
    </f:verbatim>
    </trh:script>
    </f:facet>
    </af:document>
    </f:view>
    Problem 1: when i run it, the alert box displays: Hello from undefined . i was expecting Hello from cmdButton
    Problem 2: in the line var id = component.getId, if i modify it as var id = component.getId() (just added the parentheses after method getId)
    no alert box is displayed. in javascript when a method accepts no parameters, its ok to call it with or without parentheses. why no alert
    box displayed when i add parentheses to getId.

    in javascript calling a method with or without parentheses is OK , then why the alert box in one case and no alert box in another?
    Because your assumption is wrong. Calling a function can only be done with the parenthesis. When you're not using them then you get a pointer on the function. For example:
    MyNamespace = new Object();
    MyNamespace.myUtilFunction = function()
        return "Hello world";
    alert(MyNamespace.myUtilFunction);
    alert(MyNamespace.myUtilFunction());The first alert will show something like
    "function()
    return "Hello world";
    While the second will print "Hello world". Furthermore, if a function does not exists, like "MyNamespace.myUnexistingFunction" then the first alert would show "undefined" while the second would never even pop as there would be an "MyNamespace.myUnexistingFunction is undefined" error. Consequently, if the alert is not showing with the parenthesis then I guess getId is not a valid function on UIComponent which is possible, I assumed there would be one because there's an id property, but then again, that id would not be very useful on the client side compared to the client id.
    Regards,
    ~ Simon

  • ADF Login problem

    Hi,
    I have implemented ADF Security along with a login bean and a home managed bean according to Frank Nimphius's article in the Oracle Magazine.
    Problems:
    1. In design view the login link is visible, but not in the browser (Firefox vers. 19).
    2. Only the logout link is visible
    3. When trying to logout the current page only refreshes
    Login bean
    package demo.view;
    import java.io.IOException;
    import java.util.Map;
    import javax.faces.application.FacesMessage;
    import javax.faces.context.ExternalContext;
    import javax.faces.context.FacesContext;
    import javax.security.auth.Subject;
    import javax.security.auth.callback.CallbackHandler;
    import javax.security.auth.login.FailedLoginException;
    import javax.security.auth.login.LoginException;
    import javax.servlet.RequestDispatcher;
    import javax.servlet.ServletException;
    import javax.servlet.http.HttpServletRequest;
    import javax.servlet.http.HttpServletResponse;
    import oracle.adf.share.ADFContext;
    import oracle.adf.view.rich.event.DialogEvent;
    import weblogic.security.SimpleCallbackHandler;
    import weblogic.security.URLCallbackHandler;
    import weblogic.security.services.Authentication;
    import weblogic.servlet.security.ServletAuthentication;
    public class LoginBean {
        String _username = null;
        String _password = null;
        public static String USERNAMETOKEN = "_____demoOnlyUsernameAttrString___________";
        public static String PASSWORDTOKEN = "_____demoOnlyPasswordAttrString___________";
        public LoginBean() {
            super();
        public void setUsername(String _username) {
            this._username = _username;
        public String getUsername() {
            return _username;
        public void setPassword(String _password) {
            this._password = _password;
        public String getPassword() {
            return _password;
      public void onLoginAction(DialogEvent dialogEvent) {
          if (dialogEvent.getOutcome()== DialogEvent.Outcome.ok ){
            doLogin();
          else{
            //cancel, do nothing
      private String doLogin() {
          String un = _username;
          byte[] pw = _password.getBytes();
          FacesContext ctx = FacesContext.getCurrentInstance();
          HttpServletRequest request = (HttpServletRequest)ctx.getExternalContext().getRequest();
          try {         
              CallbackHandler handler = new URLCallbackHandler(un,pw);
              Subject mySubject = weblogic.security.services.Authentication.login(handler);
              weblogic.servlet.security.ServletAuthentication.runAs(mySubject, request);
              ServletAuthentication.generateNewSessionID(request);
              //save username and password. Note that in a real application this is
              //*NOT* what you should do unencrypted. Note that this is a demo
              //Store username , password in session for later use
              //when connecting to Twitter
              ADFContext adfctx = ADFContext.getCurrent();
              Map sessionScope = adfctx.getSessionScope();
              sessionScope.put(this.USERNAMETOKEN, un);
              sessionScope.put(this.PASSWORDTOKEN, new String(pw));
                String loginUrl;
                loginUrl = "/adfAuthentication?success_url=/faces" + ctx.getViewRoot().getViewId();
              HttpServletResponse response = (HttpServletResponse)ctx.getExternalContext().getResponse();
              sendForward(request, response, loginUrl);
          } catch (FailedLoginException fle) {
              FacesMessage msg =
                  new FacesMessage(FacesMessage.SEVERITY_ERROR, "Incorrect Username or Password",
                                   "An incorrect Username or Password" +
                                   " was specified");
              ctx.addMessage("d2:it35", msg);
          } catch (LoginException le) {
              reportUnexpectedLoginError("LoginException", le);
          return null;
      private void sendForward(HttpServletRequest request,
                               HttpServletResponse response, String forwardUrl) {
          FacesContext ctx = FacesContext.getCurrentInstance();
          RequestDispatcher dispatcher = request.getRequestDispatcher(forwardUrl);
          try {
              dispatcher.forward(request, response);
          } catch (ServletException se) {
              reportUnexpectedLoginError("ServletException", se);
          } catch (IOException ie) {
              reportUnexpectedLoginError("IOException", ie);
          ctx.responseComplete();
      private void reportUnexpectedLoginError(String errType, Exception e) {
          FacesMessage msg =
              new FacesMessage(FacesMessage.SEVERITY_ERROR, "Unexpected error during login",
                               "Unexpected error during login (" + errType +
                               "), please consult logs for detail");
          FacesContext.getCurrentInstance().addMessage("d2:it35", msg);
          e.printStackTrace();
        public String logout() {
            FacesContext ctx = FacesContext.getCurrentInstance(); 
            ExternalContext ectx = ctx.getExternalContext();
            String logoutUrl = "faces" + ctx.getViewRoot().getViewId();
            ((HttpServletRequest)ectx.getRequest()).getSession().invalidate();
            try {
                ectx.redirect(logoutUrl);
            } catch (IOException e) {
                e.printStackTrace();
            return null;
    }Home managed bean
    package demo.view;
    import java.io.IOException;
    import java.util.Iterator;
    import java.util.List;
    import java.util.Map;
    import javax.el.ELContext;
    import javax.el.ExpressionFactory;
    import javax.el.ValueExpression;
    import javax.faces.context.ExternalContext;
    import javax.faces.context.FacesContext;
    import javax.faces.event.ActionEvent;
    import oracle.adf.model.binding.DCIteratorBinding;
    import oracle.adf.view.rich.component.rich.RichPopup;
    import oracle.adf.view.rich.component.rich.data.RichTree;
    import oracle.adf.view.rich.component.rich.layout.RichPanelGroupLayout;
    import oracle.adf.view.rich.component.rich.nav.RichCommandImageLink;
    import oracle.adf.view.rich.context.AdfFacesContext;
    import oracle.jbo.Key;
    import oracle.jbo.uicli.binding.JUCtrlHierBinding;
    import oracle.jbo.uicli.binding.JUCtrlHierNodeBinding;
    import oracle.jbo.uicli.binding.JUCtrlHierTypeBinding;
    import oracle.jbo.uicli.binding.JUIteratorBinding;
    import org.apache.myfaces.trinidad.component.UIXSwitcher;
    import org.apache.myfaces.trinidad.event.SelectionEvent;
    import org.apache.myfaces.trinidad.model.CollectionModel;
    import org.apache.myfaces.trinidad.model.RowKeySet;
    public class HomeManagedBean {
        private RichTree locationsTree;
        private UIXSwitcher formSwitcher;
        private RichPanelGroupLayout formPanelGroup;
        private RichPopup popupP1;
        public HomeManagedBean() {
        public void setLocationsTree(RichTree locationsTree) {
            this.locationsTree = locationsTree;
        public RichTree getLocationsTree() {
            return locationsTree;
       * Custom managed bean method that takes a SelectEvent input argument to generically
       * set the current row corresponding to the selected row in the tree. Note that this
       * method is a way to replace the "makeCurrent" EL expression (#{bindings.<tree binding>.
       * treeModel.makeCurrent}that Oracle JDeveloper adds to the tree component SelectionListener
       * property when dragging a collection from the Data Controls panel. Using this custom
       * selection listener allows developers to add pre- and post processing instructions. For
       * example, you may want to enforce PPR on a specific item after a new tree node has been
       * selected. This methods performs the following steps
       * i.   get access to the tree component
       * ii.  get access to the ADF tree binding
       * iii. set the current row on the ADF binding
       * iv.  get the information about target iterators to synchronize
       * v.   synchronize target iterator
       * @param selectionEvent object passed in by ADF Faces when configuring this method to
       * become the selection listener
       * @author Frank Nimphius
      public void onTreeSelect(SelectionEvent selectionEvent) {
        /* REPLACES */
        //#{bindings.allLocations.treeModel.makeCurrent}
       /* custom pre processing goes here */
      //get the tree information from the event object
      RichTree tree1 = (RichTree) selectionEvent.getSource();
      //in a single selection case ( a setting on the tree component ) the added set only
      //has a single entry. If there are more then using this method may not be desirable.
      //Implicitly we turn the multi select in a single select later, ignoring all set
      //entries than the first
      RowKeySet rks2 = selectionEvent.getAddedSet();
      //iterate over the contained keys. Though for a single selection use case we only expect
      //one entry in here
      Iterator rksIterator = rks2.iterator();
      //support single row selection case
      if (rksIterator.hasNext()){
        //get the tree node key, which is a List of path entries describing the
        //location of the node in the tree including its parents nodes
        List key = (List)rksIterator.next();
       //get the ADF tree  binding to work with
        JUCtrlHierBinding treeBinding = null;
        //The Trinidad CollectionModel is used to provide data to trees and tables. In the
        //ADF binding case, it contains the tree binding as wrapped data
        treeBinding = (JUCtrlHierBinding) ((CollectionModel)tree1.getValue()).getWrappedData();
        //find the node identified by the node path from the ADF binding layer. Note that
        //we don't need to know about the name of the tree binding in the PageDef file because
        //all information is provided
        JUCtrlHierNodeBinding nodeBinding = nodeBinding = treeBinding.findNodeByKeyPath(key);
        //the current row is set on the iterator binding. Because all bindings have an internal
        //reference to their iterator usage, the iterator can be queried from the ADF binding
        //object
        DCIteratorBinding _treeIteratorBinding = null;
        _treeIteratorBinding = treeBinding.getDCIteratorBinding();
        Key rowKey = nodeBinding.getRowKey();
        JUIteratorBinding iterator = nodeBinding.getIteratorBinding();
        iterator.setCurrentRowWithKey(rowKey.toStringFormat(true));
        //get selected node type information
        JUCtrlHierTypeBinding typeBinding =  nodeBinding.getHierTypeBinding();
        // The tree node rule may have a target iterator defined. Target iterators are
        // configured using the Target Data Source entry in the tree node edit dialog
        // and allow developers to declaratively synchronize an independent iterator
        // binding with the node selection in the tree.
        String targetIteratorSpelString = typeBinding.getTargetIterator();     
        //chances are that the target iterator option is not configured. We avoid
        //NPE by checking this condition
        if (targetIteratorSpelString != null && !targetIteratorSpelString.isEmpty()) {
          //resolve SPEL string for target iterator
          DCIteratorBinding targetIterator = resolveTargetIterWithSpel(targetIteratorSpelString);
          //synchronize the row in the target iterator
          targetIterator.setCurrentRowWithKey(rowKey.toStringFormat(true));
        /********************* DISPLAY INPUT FORM FOR SELECTED NODE **********************/
        //get the name of the selectected tree node object. In this sample the value is
        //adf.sample.model.DepartmentsView,adf.sample.model.EmployeesView or
        //adf.sample.model.LocationsView
        String selectedNodeObjectRef = typeBinding.getStructureDefName();
        //write selected node object reference to session
        AdfFacesContext adfFacesCtx = AdfFacesContext.getCurrentInstance();
        Map viewScope = adfFacesCtx.getViewScope();
        viewScope.put("nodeRef",selectedNodeObjectRef);
        //refresh form display
        adfFacesCtx.addPartialTarget(this.getFormPanelGroup());
       * Helper method to resolve EL expression into DCIteratorBinding instance
       * @param spelExpr the SPEL expression starting with ${...}
       * @return DCIteratorBinding instance
      private DCIteratorBinding resolveTargetIterWithSpel(String spelExpr){
       FacesContext fctx = FacesContext.getCurrentInstance();
       ELContext elctx = fctx.getELContext();
       ExpressionFactory elFactory = fctx.getApplication().getExpressionFactory();
       ValueExpression valueExpr = elFactory.createValueExpression(elctx, spelExpr,Object.class);
       DCIteratorBinding dciter = (DCIteratorBinding) valueExpr.getValue(elctx);  
       return dciter;
        public void setFormPanelGroup(RichPanelGroupLayout formPanelGroup) {
            this.formPanelGroup = formPanelGroup;
        public RichPanelGroupLayout getFormPanelGroup() {
            return formPanelGroup;
        //based on the current state of the login link,
        //log user in or out
        public void onLoginLogout(ActionEvent actionEvent) {
            RichCommandImageLink rcil = (RichCommandImageLink) actionEvent.getComponent();
            String commandLinkIcon = rcil.getIcon();
            if (commandLinkIcon.indexOf("glbl_login_msg.gif") >0){
              //login
              RichPopup.PopupHints hints = new RichPopup.PopupHints();
              popupP1.show(hints);
            else{
              //logout        
              FacesContext fctx = FacesContext.getCurrentInstance();
              ExternalContext ectx = fctx.getExternalContext();
                try {
                    ectx.redirect("/adfAuthentication?logout=true&end_url=/faces/home.jspx");
                } catch (IOException e) {
                    e.printStackTrace();
        public void setPopupP1(RichPopup popupP1) {
            this.popupP1 = popupP1;
        public RichPopup getPopupP1() {
            return popupP1;
    }Source code in home page
    <af:commandImageLink text="Logout" id="commandImageLink1"
                                                              icon="#{resource['images:glbl_logout.gif']}"
                                                         rendered="#{securityContext.authenticated}" partialSubmit="true"
                                                         immediate="false"
                                                              inlineStyle="font-family:Arial, Helvetica, sans-serif; font-size:11px; color:White;"
                                                                 action="#{LoginBean.logout}"/>
                                         <af:commandImageLink text="Login" id="cil1"
                                                              icon="#{resource['images:glbl_login_msg.gif']}"
                                                         rendered="#{!securityContext.authenticated}"
                                                              inlineStyle="font-family:Arial, Helvetica, sans-serif; font-size:11px; color:White;"
                                                              action="#{LoginBean.toString}">
                                        <af:showPopupBehavior popupId="p1" triggerType="action" align="startAfter"
                                                              alignId="cil1"/>
                                    </af:commandImageLink>
                                    <af:popup id="p1" binding="#{HomeManagedBean.popupP1}">
                                        <af:dialog id="d2" title="Please Login" type="okCancel" closeIconVisible="false"
                                                   modal="true" stretchChildren="none"
                                                   dialogListener="#{LoginBean.onLoginAction}">
                                            <af:panelFormLayout id="pfl5">
                                                <af:inputText label="Username" id="it34" columns="20"
                                                              value="#{LoginBean.username}"/>
                                                <af:inputText label="Password" id="it35" secret="true" columns="20"
                                                              value="#{LoginBean.password}"/>
                                                <af:message id="m2" for="it35" messageType="error"/>
                                            </af:panelFormLayout>
                                        </af:dialog>
                                    </af:popup>Other settings:
    1. No welcome page set in web.xml
    2. No redirect page set in jazn-data.xml
    3. Users, Enterprise and application roles set in ADF Security
    4. Managed Beans registered in adfc-config.xml
    Help greatly appreciated!

    Without going through all the code:
    the visibility of the links depends on
    logout:
    rendered="#{securityContext.authenticated}"
    login:
    rendered="#{!securityContext.authenticated}"This means, if you see the logout link, but not the loging link, the framework assumes that you are logged in already.
    Investigate in this direction.
    Timo

  • Tomahawk t:inputDate problem in IE

    I am using t:inputDate with popupCalendar attribute set to "true". It works perfectly in Firefox but the calendar can't popup in IE. Would anyone please help me? Thanks very much!
    Note: I have already added extension filters and I'm using tomahawk version 1.1.5
    Here is my JSP source code:
    <html>
         <head>
              <title>Stock Management System</title>
         </head>
         <body>
              <f:view>
                   <h:form>
                        <t:outputText value="Welcome "/>
                        <t:outputText value="#{account.engName}!"/>
                        <p>
                        <t:panelGrid columns="3">
                             <t:commandLink tabindex="100" value="Save" action="#{transactionHandler.insert}"/>
                             <t:commandLink tabindex="101" value="Cancel" action="main" immediate="true"/>
                             <h:outputLink tabindex="102" value="#{facesContext.externalContext.request.contextPath}/pages/logout.jsp">
                                  <t:outputText value="Logout"/>
                             </h:outputLink>
                        </t:panelGrid>
                        <p>
                        <t:panelGrid id="main" columns="3">
                             <t:outputText value="Buy / Sell"/>
                             <t:selectOneMenu tabindex="1" id="action" value="#{transaction.action}" required="true">
                                  <f:selectItem itemValue="B" itemLabel="Buy"/>
                                  <f:selectItem itemValue="S" itemLabel="Sell"/>
                             </t:selectOneMenu>
                             <t:message for="action"/>
                             <t:outputText value="Date"/>
                             <t:inputDate id="date" type="date" popupCalendar="true" value="#{transaction.date}"/>
                             <t:message for="date"/>
                             <t:outputText value="Stock Code"/>
                             <t:inputText tabindex="5" id="stockCd" value="#{transaction.stockCd}" size="4" dir="RTL" required="true">
                                  <f:validateLongRange maximum="9999" minimum="1"/>
                             </t:inputText>
                             <t:message for="stockCd"/>
                             <t:outputText value="Quantity" />
                             <t:inputText tabindex="6" id="qty" value="#{transaction.qty}" size="8" dir="RTL" required="true">
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="qty"/>
                             <t:outputText value="Unit Price" />
                             <t:inputText tabindex="7" id="unitPrice" value="#{transaction.unitPrice}" size="8" dir="RTL" required="true">
                                  <f:convertNumber pattern="$#,##0.000"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="unitPrice"/>
                             <t:outputText value="Brokerage" />
                             <t:inputText tabindex="8" id="brokerage" value="#{transaction.brokerage}" size="8" dir="RTL">
                                  <f:convertNumber pattern="$#,##0.00"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="brokerage"/>
                             <t:outputText value="Levy Fee" />
                             <t:inputText tabindex="9" id="levy" value="#{transaction.levy}" size="8" dir="RTL">
                                  <f:convertNumber pattern="$#,##0.00"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="levy"/>
                             <t:outputText value="Stamp Duty" />
                             <t:inputText tabindex="10" id="stampDuty" value="#{transaction.stampDuty}" size="8" dir="RTL">
                                  <f:convertNumber pattern="$#,##0.00"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="stampDuty"/>
                             <t:outputText value="Trading Fee" />
                             <t:inputText tabindex="11" id="tradingFee" value="#{transaction.tradingFee}" size="8" dir="RTL">
                                  <f:convertNumber pattern="$#,##0.00"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="tradingFee"/>
                             <t:outputText value="Investment Compensation Levy" />
                             <t:inputText tabindex="12" id="invCompLevy" value="#{transaction.invCompLevy}" size="8" dir="RTL">
                                  <f:convertNumber pattern="$#,##0.00"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="invCompLevy"/>
                             <t:outputText value="Handling Charge" />
                             <t:inputText tabindex="13" id="handlingChrg" value="#{transaction.handlingCharge}" size="8" dir="RTL">
                                  <f:convertNumber pattern="$#,##0.00"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="handlingChrg"/>
                             <t:outputText value="Deposit Charge" />
                             <t:inputText tabindex="14" id="depositChrg" value="#{transaction.depositCharge}" size="8" dir="RTL">
                                  <f:convertNumber pattern="$#,##0.00"/>
                                  <f:validateDoubleRange minimum="0"/>
                             </t:inputText>
                             <t:message for="depositChrg"/>
                        </t:panelGrid>
                   </h:form>
              </f:view>
         </body>     
    </html>
    Here is the generated HTML results:
    <html>
         <head>
    <link rel="stylesheet" href="/Stock/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/11796022/calendar.HtmlCalendarRenderer/WH/theme.css" type="text/css" />
    <link rel="stylesheet" href="/Stock/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/11796022/calendar.HtmlCalendarRenderer/DB/theme.css" type="text/css" />
    <script type="text/javascript" src="/Stock/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/11796022/prototype.PrototypeResourceLoader/prototype.js"><!--
    //--></script>
    <script type="text/javascript" src="/Stock/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/11796022/calendar.HtmlCalendarRenderer/date.js"><!--
    //--></script>
    <script type="text/javascript" src="/Stock/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/11796022/calendar.HtmlCalendarRenderer/popcalendar.js"><!--
    //--></script>
              <title>Stock Management System</title>
         </head>
         <body>
                   <form id="_idJsp0" name="_idJsp0" method="post" action="/Stock/pages/add_transaction.jsf" enctype="application/x-www-form-urlencoded">
                        Welcome
                        Tsang Shiu Ching!
                        <p>
                        <table><tbody><tr><td><script type="text/javascript"><!--
         function oamSetHiddenInput(formname, name, value)
              var form = document.forms[formname];
              if(typeof form.elements[name]=='undefined')
                   var newInput = document.createElement('input');
                   newInput.setAttribute('type','hidden');
                   newInput.setAttribute('name',name);
                   newInput.setAttribute('value',value);
                   form.appendChild(newInput);
              else
                   form.elements[name].value=value;
         function oamClearHiddenInput(formname, name, value)
              var form = document.forms[formname];
              if(typeof form.elements[name]!='undefined')
                   form.elements[name].value=null;
         function oamSubmitForm(formName, linkId, target, params)
              var clearFn = 'clearFormHiddenParams_'+formName.replace(/-/g, '\$:').replace(/:/g,'_');
              if(typeof eval('window.'+clearFn)!='undefined')
                   eval('window.'+clearFn+'(formName)');
              if(typeof window.getScrolling!='undefined')
                   oamSetHiddenInput(formName,'autoScroll',getScrolling());
              var oldTarget = '';
              if((typeof target!='undefined') && target != null)
                   oldTarget=document.forms[formName].target;
                   document.forms[formName].target=target;
              if((typeof params!='undefined') && params != null)
                   for(var i=0; i<params.length; i++)
                        oamSetHiddenInput(formName,params[0], params[i][1]);
              oamSetHiddenInput(formName,formName +':'+'_idcl',linkId);
              if(document.forms[formName].onsubmit)
                   var result=document.forms[formName].onsubmit();
                   if((typeof result=='undefined')||result)
                        document.forms[formName].submit();
              else
                   document.forms[formName].submit();
              if(oldTarget==null) oldTarget='';
              document.forms[formName].target=oldTarget;
              if((typeof params!='undefined') && params != null)
                   for(var i=0; i<params.length; i++)
                        oamClearHiddenInput(formName,params[i][0], params[i][1]);
              oamClearHiddenInput(formName,formName +':'+'_idcl',linkId);return false;
    //--></script>Save
    <input type="hidden" name="autoScroll" />
    </td><td>Cancel</td><td><a id="_idJsp0:_idJsp6" name="_idJsp0:_idJsp6" href="/Stock/pages/logout.jsp" tabindex="102">Logout</a></td></tr>
    </tbody></table>
                        <p>
                        <table id="_idJsp0:main"><tbody><tr><td>Buy / Sell</td><td><select id="_idJsp0:action" name="_idJsp0:action" size="1" tabindex="1">     <option value="B">Buy</option>     <option value="S">Sell</option></select></td><td></td></tr>
    <tr><td>Date</td><td>
    <span id="_idJsp0:date"><input id="_idJsp0:date.day" name="_idJsp0:date.day" size="2" maxlength="2" /><select id="_idJsp0:date.month" name="_idJsp0:date.month" size="1"><option value="-1" selected="selected"></option>          <option value="1">&#19968;&#26376;</option>          <option value="2">&#20108;&#26376;</option>          <option value="3">&#19977;&#26376;</option>          <option value="4">&#22235;&#26376;</option>          <option value="5">&#20116;&#26376;</option>          <option value="6">&#20845;&#26376;</option>          <option value="7">&#19971;&#26376;</option>          <option value="8">&#20843;&#26376;</option>          <option value="9">&#20061;&#26376;</option>          <option value="10">&#21313;&#26376;</option>          <option value="11">&#21313;&#19968;&#26376;</option>          <option value="12">&#21313;&#20108;&#26376;</option></select><input id="_idJsp0:date.year" name="_idJsp0:date.year" size="4" maxlength="4" /><span id="_idJsp0:dateSpan"></span><script type="text/javascript"><!--
    var _5FidJsp0_3AdateCalendarVar=new org_apache_myfaces_PopupCalendar();
    _5FidJsp0_3AdateCalendarVar.initData.imgDir = "/Stock/faces/myFacesExtensionResource/org.apache.myfaces.renderkit.html.util.MyFacesResourceLoader/11796022/calendar.HtmlCalendarRenderer/DB/";
    _5FidJsp0_3AdateCalendarVar.initData.monthName = new Array("\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00\u6708","\u5341\u4E8C\u6708");
    _5FidJsp0_3AdateCalendarVar.initData.dayName = new Array("\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D");
    _5FidJsp0_3AdateCalendarVar.initData.startAt = 0;
    _5FidJsp0_3AdateCalendarVar.dateFormatSymbols.weekdays = new Array("\u661F\u671F\u65E5","\u661F\u671F\u4E00","\u661F\u671F\u4E8C","\u661F\u671F\u4E09","\u661F\u671F\u56DB","\u661F\u671F\u4E94","\u661F\u671F\u516D");
    _5FidJsp0_3AdateCalendarVar.dateFormatSymbols.shortWeekdays = new Array("\u65E5","\u4E00","\u4E8C","\u4E09","\u56DB","\u4E94","\u516D");
    _5FidJsp0_3AdateCalendarVar.dateFormatSymbols.shortMonths = new Array("1\u6708","2\u6708","3\u6708","4\u6708","5\u6708","6\u6708","7\u6708","8\u6708","9\u6708","10\u6708","11\u6708","12\u6708");
    _5FidJsp0_3AdateCalendarVar.dateFormatSymbols.months = new Array("\u4E00\u6708","\u4E8C\u6708","\u4E09\u6708","\u56DB\u6708","\u4E94\u6708","\u516D\u6708","\u4E03\u6708","\u516B\u6708","\u4E5D\u6708","\u5341\u6708","\u5341\u4E00\u6708","\u5341\u4E8C\u6708");
    _5FidJsp0_3AdateCalendarVar.dateFormatSymbols.eras = new Array("\u897F\u5143\u524D","\u897F\u5143");
    _5FidJsp0_3AdateCalendarVar.dateFormatSymbols.ampms = new Array("\u4E0A\u5348","\u4E0B\u5348");
    _5FidJsp0_3AdateCalendarVar.init(document.getElementById('_idJsp0:dateSpan'));
    //--></script><input type="button" onclick="_5FidJsp0_3AdateCalendarVar._popUpCalendarForInputDate('_idJsp0:date','yy'&#24180;'M'&#26376;'d'&#26085;'');" value="..." /></span></td><td></td></tr>
    <tr><td>Stock Code</td><td><input id="_idJsp0:stockCd" name="_idJsp0:stockCd" type="text" value="0" size="4" dir="RTL" tabindex="5" /></td><td></td></tr>
    <tr><td>Quantity</td><td><input id="_idJsp0:qty" name="_idJsp0:qty" type="text" value="0.0" size="8" dir="RTL" tabindex="6" /></td><td></td></tr>
    <tr><td>Unit Price</td><td><input id="_idJsp0:unitPrice" name="_idJsp0:unitPrice" type="text" value="$0.000" size="8" dir="RTL" tabindex="7" /></td><td></td></tr>
    <tr><td>Brokerage</td><td><input id="_idJsp0:brokerage" name="_idJsp0:brokerage" type="text" value="$0.00" size="8" dir="RTL" tabindex="8" /></td><td></td></tr>
    <tr><td>Levy Fee</td><td><input id="_idJsp0:levy" name="_idJsp0:levy" type="text" value="$0.00" size="8" dir="RTL" tabindex="9" /></td><td></td></tr>
    <tr><td>Stamp Duty</td><td><input id="_idJsp0:stampDuty" name="_idJsp0:stampDuty" type="text" value="$0.00" size="8" dir="RTL" tabindex="10" /></td><td></td></tr>
    <tr><td>Trading Fee</td><td><input id="_idJsp0:tradingFee" name="_idJsp0:tradingFee" type="text" value="$0.00" size="8" dir="RTL" tabindex="11" /></td><td></td></tr>
    <tr><td>Investment Compensation Levy</td><td><input id="_idJsp0:invCompLevy" name="_idJsp0:invCompLevy" type="text" value="$0.00" size="8" dir="RTL" tabindex="12" /></td><td></td></tr>
    <tr><td>Handling Charge</td><td><input id="_idJsp0:handlingChrg" name="_idJsp0:handlingChrg" type="text" value="$0.00" size="8" dir="RTL" tabindex="13" /></td><td></td></tr>
    <tr><td>Deposit Charge</td><td><input id="_idJsp0:depositChrg" name="_idJsp0:depositChrg" type="text" value="$0.00" size="8" dir="RTL" tabindex="14" /></td><td></td></tr>
    </tbody></table>
                   <input type="hidden" name="_idJsp0_SUBMIT" value="1" /><input type="hidden" name="_idJsp0:_link_hidden_" /><input type="hidden" name="_idJsp0:_idcl" /><script type="text/javascript"><!--
         function clear__5FidJsp0()
              clearFormHiddenParams__idJsp0('_idJsp0');
         function clearFormHiddenParams__idJsp0(currFormName)
              var f = document.forms['_idJsp0'];
              f.elements['_idJsp0:_link_hidden_'].value='';
              f.elements['_idJsp0:_idcl'].value='';
              f.target='';
         clearFormHiddenParams__idJsp0();
    //--></script><input type="hidden" name="javax.faces.ViewState" id="javax.faces.ViewState" value="rO0ABXVyABNbTGphdmEubGFuZy5PYmplY3Q7kM5YnxBzKWwCAAB4cAAAAAN0AAIxM3B0ABovcGFnZXMvYWRkX3RyYW5zYWN0aW9uLmpzcA==" /></form>
         <!-- MYFACES JAVASCRIPT -->
    <script type="text/javascript"><!--
         function getScrolling()
              var x = 0; var y = 0;if (self.pageXOffset || self.pageYOffset)
                   x = self.pageXOffset;
                   y = self.pageYOffset;
              else if ((document.documentElement && document.documentElement.scrollLeft)||(document.documentElement && document.documentElement.scrollTop))
                   x = document.documentElement.scrollLeft;
                   y = document.documentElement.scrollTop;
              else if (document.body)
                   x = document.body.scrollLeft;
                   y = document.body.scrollTop;
              return x + "," + y;
    //--></script>
    </body>     
    </html>

    i am having the same problem
    I have a page with three use of input date tomahawk
    2 of them sometimes work as expected (i.e. the calendar appear beside the icon), 1 of them never work (the calendar shows up like 1/2 screen below the icon)

  • JDeveloper ADF Faces Problem: Expression language

    Error(): Expression Language not supported in compile time attribute test
    I have followed an ADF Faces example from the Oracle Website. Concerning a database + ADF Faces
    http://www.oracle.com/technology/pub/articles/cioroianu_jsfadf_v4.html
    I followed the tutorial correct but everytime i try to run it. I get following error:
    Error(): Expression Language not supported in compile time attribute test
    It has something to do with following line of code
    <c:if test="${subscriber == null || !subscriber.loggedIn}">
    The error appears on every page where "<c:" appears.
    I have imported the right class library
    <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
    Does anybody have any idea what i can do?

    Dear Tim,
    What a chance!!! I've got the same problem as you?!
    I've tried almost everything, but still haven't succeeded to solve it!
    Hopefully someone can help us.
    Greetings

  • ADF/JClient problem

    Hi @all,
    I have a problem using bc4j. I have an ADF/JClient application that shows a Master/Detail Log from a database to the user.
    But the connection to the database should by dynamic: With a combo box I select the database to connect to
    and than I want to see the Master/Detail Log.
    Actually, the problem is that the Master/Detail tables (normal JTables with BC4J bindings) do not refresh their views,
    so I ever see the same Matser/Detail Log.
    The connection to the database is established using my own classes MyConnectionStrategy (derived from DefaultConnectionStrategy)
    and MyEnvInfoProvider (derived from DefaultEnvInfoProvider).
    Bootstrap code look like this:
    JUMetaObjectManager.setBaseErrorHandler(new JUErrorHandlerDlg());
    JUMetaObjectManager.getJUMom().setJClientDefFactory(null);
    mCtx = new BindingContext();
    mCtx.put(DataControlFactory.APP_PARAM_ENV_INFO, new MyEnvInfoProvider(mDBConn));
    HashMap map = new HashMap(4);
    map.put(DataControlFactory.APP_PARAMS_BINDING_CONTEXT, mCtx);
    JUMetaObjectManager.loadCpx("DataBindings.cpx", map);
    mDataControl = (DCDataControl)mCtx.get("AppModuleDataControl1");
    mDataControl.setClientApp(DCDataControl.JCLIENT);
    How can I update (refresh, reinitialize, ...) the bindings between my AppMod and the 2 JTables?
    Please help me.
    Thanks in advanced,
    Dorian.

    You may use the 'key' on the row from one VO to find it in another and then set the currency using the found row.

  • ADF BC problem

    Hi,
    I just got the Oracle Jdeveloper 10g Handbook by Oracle Press. When trying the first example I run into some problem. I am supposed to create a JSP page based on ADF BC. The problem is I cant find the wizard for setting up this. The book says I should find business components under the project technologies when choosing a new gallery.
    Is there some thing I have to do to enable ADF BC. I'm using developer preview 10.1.3.
    Please help
    /Stefan

    The book is about the production version of Oracle JDeveloper which is 10.1.2. - the 10.1.3 version you are using is still not in production, and the preview that you have doesn't have the ADF BC parts in it.
    So download 10.1.2 from http://otn.oracle.com/products/jdev

  • ADF Styling Problem,

    Hello everybody ,
    i have a problem styling an ADF Application , i followed this example
    http://technology.amis.nl/blog/5722/using-adf-faces-11g-skinning-for-setting-the-styles-of-specific-component-instances-or-groups-of-instances
    and i created the following Css in my customskin.css
    af|inputText::label
    color:Blue;
    but it doesn't change anything , the labels of the inputtexts are still brown according to blafplus-rich theme of oracle .
    The project doesn't apply the blue color to the labels of the inputText boxes
    Second thing , in the above article the author told that the CSS editor will autocomplete code with you whereas it recognize neither inputText nor Label element . How can i solve this problem too ?
    How can i solve this problem ?
    Please help me urgently !

    Hi,
    Second thing , in the above article the author told that the CSS editor will autocomplete code with you whereas it recognize neither inputText nor Label element . How can i solve this problem too ?
    Tools --> Preferences --> CSS
    Enable ADF CSS
    Frank

  • ADF valuechangeListener Problem

    Hi,
    I am facing problem with ADF selectonechoice valuechangeListener.
    Problem is i have four valuechangeListeners. those are dependent List Boxes. If i perform action on one valuechangeListener all other VC 's also calling. due to this i am facing problems. how to prevent calling other VCs. why it is calling other VCS also. please reply me very urgent
    Thanks
    Jyothi

    Hi,
    a value change listener fires for any value that has been changed in a form (assuming the component has a ValueChangeListener applied). So obviously in your case more than one field has been changed, which shouldn't be the case if autosubmit=true is used
    Frank

  • ADF Table problem !

    hello Oracles;
    i am using the JDev 11 to create an ADF Application, which allows me to display in a ADF table for a Product Table From the DB (using Oracle XE)
    i managed to display the table in the page with a form to make some changes in it.
    BUT the problem is :
    HOW can i save this changes into the DB ?
    and if i want to add or Delete an element too, i want to know how to save the oprations i made into the DB.
    im using a JDBC connection,
    i tried to add the Action attribute in the submit button code, wich is related to a class that manage the DB, but its not working !!!
    thank you in advance;

    okey to make things clear ;
    ive created the application following this Tutorial. but they got the datas from the constructor simply with out DB.
    so i made a JDBC connection with the DB and took the datas and put them in a collection and after that i display them in ADF Table.
    now i want to add some buttons to the form like "add new product"wich gonna add the product in the DB and display it add it too in the ADF table.
    i ve managed to do either adding the product in th DB without displaying it in the adf table or ^displaying it with adding in the DB.
    thank you .

  • ADF cache problem

    Hello,
    I'm developing a web application with an ADF tree accessing to a Content DB repository. When I deploy the application and navigate to the tree everything look fine. The problem occurs, when the content of the repository changed outside of the web application (e.g. a file will be deleted with Oracle drive), the tree doesn't display the changes. The only way to get the right state of the tree, clear the browser cache and reload the page again. In my opinion it looks like a caching problem. Putting the following meta information in the html header also failed!
    <meta http-equiv="pragma" content="no-cache"/>
    <meta http-equiv="expires" content="0"/>
    <meta http-equiv="cache-control" content="no-cache"/>
    Is there a possibility to disable the caching of such ADF components?
    Hope you can help me!
    Thanks,
    Alex

    This will probably help you: http://www.oracle.com/technology/products/ias/web_cache/afc/index.html
    Regards,
    Koen Verhulst

  • ADF Validation problem

    Dear all,
    I use adf validation something like this <af:inputText id="it1" required="true"/>.
    As i think, validation should trigger when the user click on submit button.
    But this kind of validation trigger on any click on the page. (eg. menu, panel box collapse and expand)
    So, even user don't want to submit the input , they want to go others page they need to fill this text box.
    Is there any solution for that?
    With Regards,
    WP
    Edited by: user8729650 on Oct 26, 2009 8:50 PM

    Thanks for helping me...
    This is my code on jsp. i put immediate=true. but it still validate.
    <af:form id="f1" >
    <af:pageTemplate viewId="/StarsTemplate.jspx" id="pt1" >
    <f:facet name="SideMenu"/>
    <f:facet name="Main">
    <af:panelTabbed id="pt2" >
    <af:showDetailItem text="showDetailItem 1" id="sdi1" immediate="true">
    <af:panelBox text="PanelBox1" id="pb1" immediate="true">
    <f:facet name="toolbar"/>
    <af:panelGroupLayout layout="vertical" >
    <af:inputText label="Label 1" >
    <af:validateLength maximum="10"/>
    </af:inputText>
    <af:inputText label="Label 2" immediate="true" id="label2"
    validator="#{ConfirmBean.CustomValidate}" value="#{ConfirmBean.test}"
    >
    </af:inputText> <af:message id="m1" for="label2" messageType="error" />
    <af:separator/>
    <af:inputText id="it1" required="true" immediate="true"/>
    <af:panelGroupLayout layout="horizontal">
    <af:commandButton text="Delete">
    <af:showPopupBehavior popupId="confirm" triggerType="action" align="afterEnd"/>
    </af:commandButton>
    </af:panelGroupLayout>
    <af:popup id="confirm">
    <af:dialog title="Confirm" dialogListener="#{ConfirmBean.dialogListener}">
    <af:activeOutputText value="You really want to save all changes?"/>
    </af:dialog>
    </af:popup>
    <af:commandButton text="commandButton 1" immediate="true" action="#{ConfirmBean.save}" id="cb1"/>
    </af:panelGroupLayout>
    </af:panelBox>
    <af:panelBox text="PanelBox2" id="pb2">
    <f:facet name="toolbar"/>
    <af:inputDate label="Label 1" id="id1"/>
    </af:panelBox>
    </af:showDetailItem>
    <af:showDetailItem text="showDetailItem 3" id="sdi3">
    <af:panelBox text="PanelBox3" id="pb3">
    <f:facet name="toolbar"/>
    </af:panelBox>
    </af:showDetailItem>
    </af:panelTabbed>
    </f:facet>
    </af:pageTemplate>
    </af:form>

  • ADF CollectionModel problem

    Hi,
    I am using ADF components to build a session object “newRecurringContractAddSessionDTO” from user input, each time the user adds an item the session object will grow by one item.
    I am taking the input from newItemTable RecurringContractLineItemDTO class object
    and adding it to existingItemsTable newRecurringContractAddCollectionModel. recurringContractLineItemDTOModel list.
    the problem is each time I add a new item to the recurringContractLineItemDTOModel list all the items in the recurringContractLineItemDTOModel list change to the same value of the last item I am adding?
    her is the code:
    JSP:
    <cod>
    <af:iterator id="mainIterator" value="#{recurringContractBD.newRecurringContractAddCollectionModel}" var="contracts">
    <af:table id="newItemTable" value="#{contracts.newRecurringContractLineItemDTO}" var="newItem" banding="row">
    </ af:table>
    <af:table id="existingItemsTable" value="#{contracts.recurringContractLineItemDTOModel}" bandingInterval="1" var="items">
    </ af:table>
    </ af:iterator
    </code>
    -- mainIterator is bound to newRecurringContractAddCollectionModel which holds an ArrayList of RecurringContractDTO class object
    -- newItemTable is bound to RecurringContractDTO .RecurringContractLineItemDTO class object
    -- existingItemsTable is bound to newRecurringContractAddCollectionModel. recurringContractLineItemDTOModel which holds an
    ArrayList of RecurringContractDTO .RecurringContractLineItemDTO class object
    <code>
    //==========================================================
    //this method is executed when the user clicks on the add button in the JSP
    //=========================================================
    public String addRecurringContractLineItemToSessionObject() throws Exception
    String addResult = "";
    int updateRecurringContractCollectionModelSelectedRowIndex = -1;
    RecurringContractDTO recurringContractSessionDTO = (RecurringContractDTO) FacesContext.getCurrentInstance().getExternalContext().getSessionMap().get("newRecurringContractAddSessionDTO");
    //get all contracts listed on the page
    ArrayList recurringContractUpdatedDTOList = (ArrayList) newRecurringContractAddCollectionModel.getWrappedData();
    RecurringContractDTO recurringContractUpdatedDTO = (RecurringContractDTO) recurringContractUpdatedDTOList.get(0);
    //get all line items for selected contract
    ArrayList recurringContractLineItemDTOList = new ArrayList();
    if(recurringContractSessionDTO.getRecurringContractLineItemDTOModel() != null && recurringContractSessionDTO.getRecurringContractLineItemDTOModel().getRowCount() != 0)
    recurringContractLineItemDTOList = (ArrayList) recurringContractSessionDTO.getRecurringContractLineItemDTOModel().getWrappedData();
    //add the new line item to the line item model
    recurringContractLineItemDTOList.add(recurringContractUpdatedDTO.getNewRecurringContractLineItemDTO());
    CollectionModel recurringContractExistingLineItemModel = new SortableModel();
    recurringContractExistingLineItemModel.setWrappedData((Object) recurringContractLineItemDTOList);
    //update the line items of the selected contract
    recurringContractSessionDTO.setRecurringContractLineItemDTOModel(recurringContractExistingLineItemModel);
    recurringContractSessionDTO.setHasLineItems(true);
    FacesContext fc = FacesContext.getCurrentInstance();
    HttpSession session = (HttpSession) fc.getExternalContext().getSession(false);
    session.removeAttribute("newRecurringContractAddSessionDTO");
    session.setAttribute("newRecurringContractAddSessionDTO", recurringContractSessionDTO);
    return addResult;
    //=====================================================
    // collection model value is set to the return value of
    // searchRecurringContractSessionObject() which returns
    // the value of the Session variable in an ArrayList
    //====================================================
    public CollectionModel getNewRecurringContractAddCollectionModel()
    try
    if (newRecurringContractAddCollectionModel == null)
    newRecurringContractAddCollectionModel = new SortableModel();
    newRecurringContractAddCollectionModel.setWrappedData((Object) searchRecurringContractSessionObject());
    catch (Exception ex)
    ex.printStackTrace();
    return newRecurringContractAddCollectionModel;
    //=====================================================
    // returns the value of the Session variable in an ArrayList
    //====================================================
    public ArrayList searchRecurringContractSessionObject() throws Exception
    ArrayList recurringContractDTOList = new ArrayList();
    RecurringContractDTO recurringContractDTO = new RecurringContractDTO();
    FacesContext fc = FacesContext.getCurrentInstance();
    HttpSession session = (HttpSession) fc.getExternalContext().getSession(false);
    if(session.getAttribute("newRecurringContractAddSessionDTO") != null)
    recurringContractDTO = (RecurringContractDTO) session.getAttribute("newRecurringContractAddSessionDTO");
    recurringContractDTOList.add(recurringContractDTO);
    return recurringContractDTOList;
    </code>
    Thank you
    Message was edited by:
    user600790

    Hi,
    I am using ADF components to build a session object “newRecurringContractAddSessionDTO” from user input, each time the user adds an item the session object will grow by one item.
    I am taking the input from newItemTable RecurringContractLineItemDTO class object
    and adding it to existingItemsTable newRecurringContractAddCollectionModel. recurringContractLineItemDTOModel list.
    the problem is each time I add a new item to the recurringContractLineItemDTOModel list all the items in the recurringContractLineItemDTOModel list change to the same value of the last item I am adding?
    her is the code:
    JSP:
    <cod>
    <af:iterator id="mainIterator" value="#{recurringContractBD.newRecurringContractAddCollectionModel}" var="contracts">
    <af:table id="newItemTable" value="#{contracts.newRecurringContractLineItemDTO}" var="newItem" banding="row">
    </ af:table>
    <af:table id="existingItemsTable" value="#{contracts.recurringContractLineItemDTOModel}" bandingInterval="1" var="items">
    </ af:table>
    </ af:iterator
    </code>
    -- mainIterator is bound to newRecurringContractAddCollectionModel which holds an ArrayList of RecurringContractDTO class object
    -- newItemTable is bound to RecurringContractDTO .RecurringContractLineItemDTO class object
    -- existingItemsTable is bound to newRecurringContractAddCollectionModel. recurringContractLineItemDTOModel which holds an
    ArrayList of RecurringContractDTO .RecurringContractLineItemDTO class object
    <code>
    //==========================================================
    //this method is executed when the user clicks on the add button in the JSP
    //=========================================================
    public String addRecurringContractLineItemToSessionObject() throws Exception
    String addResult = "";
    int updateRecurringContractCollectionModelSelectedRowIndex = -1;
    RecurringContractDTO recurringContractSessionDTO = (RecurringContractDTO) FacesContext.getCurrentInstance().getExternalContext().getSessionMap().get("newRecurringContractAddSessionDTO");
    //get all contracts listed on the page
    ArrayList recurringContractUpdatedDTOList = (ArrayList) newRecurringContractAddCollectionModel.getWrappedData();
    RecurringContractDTO recurringContractUpdatedDTO = (RecurringContractDTO) recurringContractUpdatedDTOList.get(0);
    //get all line items for selected contract
    ArrayList recurringContractLineItemDTOList = new ArrayList();
    if(recurringContractSessionDTO.getRecurringContractLineItemDTOModel() != null && recurringContractSessionDTO.getRecurringContractLineItemDTOModel().getRowCount() != 0)
    recurringContractLineItemDTOList = (ArrayList) recurringContractSessionDTO.getRecurringContractLineItemDTOModel().getWrappedData();
    //add the new line item to the line item model
    recurringContractLineItemDTOList.add(recurringContractUpdatedDTO.getNewRecurringContractLineItemDTO());
    CollectionModel recurringContractExistingLineItemModel = new SortableModel();
    recurringContractExistingLineItemModel.setWrappedData((Object) recurringContractLineItemDTOList);
    //update the line items of the selected contract
    recurringContractSessionDTO.setRecurringContractLineItemDTOModel(recurringContractExistingLineItemModel);
    recurringContractSessionDTO.setHasLineItems(true);
    FacesContext fc = FacesContext.getCurrentInstance();
    HttpSession session = (HttpSession) fc.getExternalContext().getSession(false);
    session.removeAttribute("newRecurringContractAddSessionDTO");
    session.setAttribute("newRecurringContractAddSessionDTO", recurringContractSessionDTO);
    return addResult;
    //=====================================================
    // collection model value is set to the return value of
    // searchRecurringContractSessionObject() which returns
    // the value of the Session variable in an ArrayList
    //====================================================
    public CollectionModel getNewRecurringContractAddCollectionModel()
    try
    if (newRecurringContractAddCollectionModel == null)
    newRecurringContractAddCollectionModel = new SortableModel();
    newRecurringContractAddCollectionModel.setWrappedData((Object) searchRecurringContractSessionObject());
    catch (Exception ex)
    ex.printStackTrace();
    return newRecurringContractAddCollectionModel;
    //=====================================================
    // returns the value of the Session variable in an ArrayList
    //====================================================
    public ArrayList searchRecurringContractSessionObject() throws Exception
    ArrayList recurringContractDTOList = new ArrayList();
    RecurringContractDTO recurringContractDTO = new RecurringContractDTO();
    FacesContext fc = FacesContext.getCurrentInstance();
    HttpSession session = (HttpSession) fc.getExternalContext().getSession(false);
    if(session.getAttribute("newRecurringContractAddSessionDTO") != null)
    recurringContractDTO = (RecurringContractDTO) session.getAttribute("newRecurringContractAddSessionDTO");
    recurringContractDTOList.add(recurringContractDTO);
    return recurringContractDTOList;
    </code>
    Thank you
    Message was edited by:
    user600790

Maybe you are looking for