JSF 1.2_13 (Mojarra) -  h:selectOneMenu problem

I have this JSF tag in my JSP form:
<h:selectOneMenu id="selectLang" value="#{langList.selectedItem}">
      <f:selectItems value="#{langList.selectItems}" />
</h:selectOneMenu>and this backing bean:
     private List<SelectItem> selectItems;
     private String selectedItem;     
        createList();
    // getter methods
    public List<SelectItem> getSelectItems() {
         return selectItems;
    public String getSelectedItem() {
         return selectedItem;
    // setter method
    public void setSelectedItem(String selectedItem) {
         this.selectedItem = selectedItem;
    private void createList()
        selectItems = new ArrayList<SelectItem>();       
        selectItems.add(new SelectItem("1", "English"));
        selectItems.add(new SelectItem("2", "Fran&ccedil;ais"));
    }I found that I can't change "selectedItem" and "selectItems" to say, for example "selectedLang" and "selectLangs" respectively in both the JSF tag and the matching backing bean method. How odd! It seems to me that the above definitions can't be changed. If I changed them to any name at all, I get the dreaded "JSF1054: (Phase ID: RENDER_RESPONSE 6..." error - which is not really helpful in identifying the problem.
I also have another problem with "h:selectOneMenu" but I guess I might to wait for your responses before I post the problem here or in another thread.
BTW, have search the forums for existing discussion but didn't find one resembling my problem. I have already lost two days trying to figure this problem out - but not successful. Maybe the solution might be really simple...
Can someone please help? Sorry if I make any mistake since this is my very first post - just joined about 30 minutes ago -:)
cheers and regards

Further to my reply above, I've tried Mojarra (1.2_12-b01-FCS) and the new Mojarra 2.0.0 (RC b16) releases and am able to replicate the same problem with these releases - one cannot rename "selectItems" and "selectedItem" in the JSF tag as well as the backing bean. Anyway, here is my full backing bean code in the hope that someone can see a problem with it:
package example;
import java.util.ArrayList;
import java.util.List;
import javax.faces.model.SelectItem;
public class LangGenerator
     private List<SelectItem> selectItems;
     private String selectedItem;     
        createList();
    // getter methods
    public List<SelectItem> getSelectItems() {
         return selectItems;
    public String getSelectedItem() {
         return selectedItem;
    // setter method
    public void setSelectedItem(String selectedItem) {
         this.selectedItem = selectedItem;
    private void createList()
        selectItems = new ArrayList<SelectItem>();
        selectItems.add(new SelectItem("1", "English"));
        selectItems.add(new SelectItem("2", "Français"));
}and my TEST.JSP codes:
<%@ page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8" language="java" %>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title>Example</title>
</head>
<body>
     <f:view>
          <h:form id="form1">
               <h:panelGrid>
                    <h:panelGroup>          
                         <h:selectOneMenu id="selectLang" value="#{langList.selectedItem}">
                              <f:selectItems value="#{langList.selectItems}" />
                         </h:selectOneMenu>                                                  
                    </h:panelGroup>
               </h:panelGrid>
          </h:form>                                                                                
     </f:view>
</body>
</html>The PROBLEM: If I left the names as "selectItems" and "selectedItem" it render the page fine. But if I change them to "selectLangs" and "selectedLang" respectively in both the JSF tag and the supporting backing bean - it will not work, period. I'm very confused now.
Is this a bug with the Mojarra JSF implementation?

Similar Messages

  • Upgrade from JSF 1.1 to JSF 1.2 (Mojarra and MyFaces) failed.

    Dear all,
    I tried to upgrade from JSF 1.1 to JSF 1.2 but failed. The application starts OK in jsf 1.1 both myfaces and RI, but failed to start using JSF 1.2.
    My environment is as follows.
    - JDK 1.5
    - Tomcat 6.0
    - Facelet
    - JSF Mojarra 1.2
    The error is as follows, occurs when starting tomcat (my application is in context /web)
    INFO: Initializing Sun's JavaServer Faces implementation (1.2_01-b04-FCS) for context '/web'
    Feb 12, 2009 10:39:40 AM com.sun.faces.config.ConfigureListener contextInitialized
    INFO: Completed initializing Sun's JavaServer Faces implementation (1.2_01-b04-FCS) for context '/web'
    Feb 12, 2009 10:39:40 AM org.apache.catalina.core.StandardContext start
    SEVERE: Error listenerStart
    Feb 12, 2009 10:39:40 AM org.apache.catalina.core.StandardContext start
    SEVERE: Context [web] startup failed due to previous errors
    What I have included in WEB-INF/lib are:
    - JSTL 1.2 (standard.jar and jstl.jar)
    - JSF mojarra 1.2 (jsf-api.jar and jsf-impl.jar)
    - Facelets( el-api.jar, el-impl.jar, and jsf-facelet.jar)
    - commons-digester.jar
    - commons-beanutils.jar
    - commons-logging.jar
    - commons-collection.jar
    Documentation that I read from mojarra FAQ states that i need EL, but EL has been included in Facelets.
    Am i missing something? The following is the part of web.xml that i used, maybe useful to locate what i am missing.
    <web-app xmlns="[http://java.sun.com/xml/ns/j2ee]"
    xmlns:xsi="[http://www.w3.org/2001/XMLSchema-instance]"
    xsi:schemaLocation="[http://java.sun.com/xml/ns/j2ee] [http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd]"
    version="2.4">
    <context-param>
    <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
    <param-value>.xhtml</param-value>
    </context-param>
    <!-- Special Debug Output for Development -->
    <context-param>
    <param-name>facelets.DEVELOPMENT</param-name>
    <param-value>true</param-value>
    </context-param>
    <!-- Optional JSF-RI Parameters to Help Debug -->
    <context-param>
    <param-name>com.sun.faces.validateXml</param-name>
    <param-value>true</param-value>
    </context-param>
    <context-param>
    <param-name>com.sun.faces.verifyObjects</param-name>
    <param-value>true</param-value>
    </context-param>
    <!--use this if start using JSF 1.2 -->
    <context-param>
    <param-name>com.sun.faces.injectionProvider</param-name>
    <param-value>com.sun.faces.vendor.GlassFishInjectionProvider</param-value>
    </context-param>
    <servlet>
    <servlet-name>faces</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    <load-on-startup>0</load-on-startup>
    </servlet

    Hi BalusC,
    Thank you for your time answering my question.
    For the first point, you were right. Now I have downloaded the latest Mojarra release.
    As for the case of web.xml, i should mentioned that I have tried declaring it as Servlet API 2.4 and Servlet API 2.5, and still got the error. My web.xml that declares as 2.5 looks as follows:
    <web-app xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaeeweb-app_2_5.xsd"
    version="2.5">
    On the third point, maybe i stated my problem in a wrong way. What I meant was, I tried each implementation separately, and both implementation did not work.
    About Glassfish injection, i followed the step in Mojarra FAQ regarding the following error.
    JSF1033: Resource injection is DISABLED
    This error showed when i started tomcat. However, since I use the latest Mojarra release, the message error disappear. I have deleted the "glasshfish injection provider" from web.xml, and the error has disappeared.
    Here's the latest of my tomcat startup messages (after i replaced the Mojarra libraries, declared as servlet 2.5 in web xml, and removed glassfish injection provider from web.xml).
    Feb 18, 2009 9:41:58 AM org.apache.catalina.core.AprLifecycleListener init
    INFO: Loaded APR based Apache Tomcat Native library 1.1.14.
    Feb 18, 2009 9:41:58 AM org.apache.catalina.core.AprLifecycleListener init
    INFO: APR capabilities: IPv6 [false], sendfile [true], accept filters [false], random [true].
    Feb 18, 2009 9:41:59 AM org.apache.coyote.http11.Http11AprProtocol init
    INFO: Initializing Coyote HTTP/1.1 on http-80
    Feb 18, 2009 9:41:59 AM org.apache.coyote.ajp.AjpAprProtocol init
    INFO: Initializing Coyote AJP/1.3 on ajp-8009
    Feb 18, 2009 9:41:59 AM org.apache.catalina.startup.Catalina load
    INFO: Initialization processed in 772 ms
    Feb 18, 2009 9:41:59 AM org.apache.catalina.core.StandardService start
    INFO: Starting service Catalina
    Feb 18, 2009 9:41:59 AM org.apache.catalina.core.StandardEngine start
    INFO: Starting Servlet Engine: Apache Tomcat/6.0.18
    Feb 18, 2009 9:42:01 AM com.sun.faces.config.ConfigureListener contextInitialized
    INFO: Initializing Mojarra (1.2_12-b01-FCS) for context '/web'
    Feb 18, 2009 9:42:01 AM com.sun.faces.config.ConfigureListener contextInitialized
    WARNING: JSF1059: WARNING! The com.sun.faces.verifyObjects feature is to aid developers not using tools. It shouldn''t be enabled if using an IDE, or if this application is being deployed for production as it will impact application start times.
    Feb 18, 2009 9:42:06 AM org.apache.catalina.core.StandardContext start
    SEVERE: Error listenerStart
    Feb 18, 2009 9:42:06 AM org.apache.catalina.core.StandardContext start
    *SEVERE: Context [web] startup failed due to previous errors*
    Feb 18, 2009 9:42:07 AM org.apache.coyote.http11.Http11AprProtocol start
    INFO: Starting Coyote HTTP/1.1 on http-80
    Feb 18, 2009 9:42:07 AM org.apache.coyote.ajp.AjpAprProtocol start
    INFO: Starting Coyote AJP/1.3 on ajp-8009
    Feb 18, 2009 9:42:07 AM org.apache.catalina.startup.Catalina start
    INFO: Server startup in 8116 ms
    The application still failed to start.There wasnt enough information for me to digest what is actually went wrong, other than SEVERE: Listener start. And let me say this again, the application starts OK when I used JSF 1.1 (Reference Implementation or MyFaces).
    Anyone has the same experience.?
    Thanks in advance.
    Edited by: niner on Feb 17, 2009 7:11 PM

  • About SelectOneMenu problem

    How to navigate to other pages using SelectOneMenu. There is my code of index.jsp:
       <html>
       <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
       <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
       <f:view>
          <head>
             <f:loadBundle basename="messages" var="msgs"/>
             <title>
                <h:outputText value = "#{msgs.indexWindowTitle}"/>
             </title>
          </head>
          <body>
             <center>
               <h:form id="menu">
                        <h:selectOneMenu id="select_menu" >
                            <f:selectItem itemValue="0" itemLabel="#{msgs.allEmployee}"/>
                            <f:selectItem itemValue="1" itemLabel="#{msgs.employee}"/>
                            <f:selectItem itemValue="2" itemLabel="#{msgs.pieceWorker}"/>
                            <f:selectItem itemValue="3" itemLabel="#{msgs.dayWorker}"/>
                        </h:selectOneMenu>
                        <h:commandButton value="#{msgs.submit}"  action="#{DropDown.select}"/>
               </h:form>
           </body>
        </f:view>
    </html> Is there any mistakes and what shoud I do in order to navigate to other pages according to the user's choice?

    Thanks a lot, James_R~~
    According to your comment, I modified the jsp code and create a bean. However, it still had the error. Can you help me to solve it?
    index.jsp
    <html>
       <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
       <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
       <f:view>
          <head>
             <f:loadBundle basename="messages" var="msgs"/>
             <title>
                <h:outputText value = "#{msgs.indexWindowTitle}"/>
             </title>
          </head>
          <body>
             <center>
               <h:form id="menu">
                        <h:selectOneMenu value="#{form.items}" >
                            <f:selectItems value="#{form.itemsSelection}"/>
                        </h:selectOneMenu>
                        <h:commandButton value="#{msgs.submit}"  action="#{form.select}"/>
               </h:form>
           </body>
        </f:view>
    </html>                       Form.java
    import java.util.ArrayList;
    import java.util.List;
    import javax.faces.model.*;
    public class Form
      private Integer items = null;
      public Integer getItems() {
         return items;
      public void setItems(Integer newValue) {
         items = newValue;
      private SelectItem[] itemsSelection = {
         new SelectItem(new Integer(1), "All Employee"),
         new SelectItem(new Integer(2), "Employee"),
         new SelectItem(new Integer(3), "Day Worker"),
         new SelectItem(new Integer(4), "Piece Worker")
      public SelectItem[] getItemsSelection() {
         return itemsSelection;
      public Integer select() {
         return items;
    }   faces-config.xml
    <faces-config>
      <navigation-rule>
         <from-view-id>/index.jsp</from-view-id>
         <navigation-case>
         <from-outcome>0</from-outcome>
         <to-view-id>/emp_rec_vv.jsp</to-view-id>
         </navigation-case>
         <navigation-case>
         <from-outcome>1</from-outcome>
         <to-view-id>/emp_rec_vn.jsp</to-view-id>
         </navigation-case>
         <navigation-case>
         <from-outcome>2</from-outcome>
         <to-view-id>/emp_rec_vq.jsp</to-view-id>
         </navigation-case>
         <navigation-case>
         <from-outcome>3</from-outcome>
         <to-view-id>/emp_rec_vv.jsp</to-view-id>
         </navigation-case>
      </navigation-rule>
      <managed-bean>
         <managed-bean-name>form</managed-bean-name>
         <managed-bean-class>Form</managed-bean-class>
         <managed-bean-scope>session</managed-bean-scope>
      </managed-bean>
    </faces-config>There is the error message
    description The server encountered an internal error () that prevented it from fulfilling this request.
    exception
    javax.servlet.ServletException
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:209)
         sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         java.lang.reflect.Method.invoke(Method.java:324)
         org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:246)
         java.security.AccessController.doPrivileged(Native Method)
         javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
         org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:268)
         org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:162)
    root cause
    java.lang.ClassCastException
         com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:72)
         javax.faces.component.UICommand.broadcast(UICommand.java:312)
         javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:267)
         javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:381)
         com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:75)
         com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
         javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
         sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         java.lang.reflect.Method.invoke(Method.java:324)
         org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:246)
         java.security.AccessController.doPrivileged(Native Method)
         javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
         org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:268)
         org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:162)Is there any problem about the bean and the faces-config.xml? Why there is an error messages?

  • Another selectOneMenu Problem....

    Hi all,
    first of all I have to say that I'm really new to JSF (just to let you know, that this question might be really stupid...)
    Ok, following combination:
    -jsp site with a form and the following selectOneMenu:
    <h:selectOneMenu id="fileType" value='#{uploadBean.filetype}'>
     <f:selectItems value="#{uploadBean.allFiletypes}" />
    </h:selectOneMenu>
    - uploadBean (code extract):
        String filetype;
        ArrayList allFiletypes;
        public String getFiletype()
            return filetype;
        public void setFiletype(String s)
            filetype = s;
        public Collection getAllFiletypes()
            if(this.allFiletypes==null)
                 allFiletypes = new ArrayList();
                 allFiletypes.add(new SelectItem("type1"));
                 allFiletypes.add(new SelectItem("type2"));
                 allFiletypes.add(new SelectItem("type3"));
            return allFiletypes;
        public void setAllFiletypes(Collection list)
            allFiletypes = new ArrayList(list);
        }I can see the select menu filled with the items "type1" .. "type3", but when I selected one type and submitted my form, the filetype is <b>null</b>.
    I tried quite a few things and also read quite a few topics in the forum, but either I'm just too stupid to understand them or ... I don't know.
    Hopefully one of you has pity with me and has a small look over my problem.
    I would be really thankful (as I was trying to solve this problem for nearly the whole day today and as I'm quite sure, it's a stupid mistake ;-) ).
    Thanks in advance and greetings!
    Steffi

    OK, these are my codes:
    sample.jsp:
    <!doctype html public "-//w3c//dtd html 4.0 transitional//en">
    <html>
        <%@ page contentType="text/html;charset=shift_jis" %>
        <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h" %>
        <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f" %>
    <head>
    </head>
    <body>
    <f:view>
    <h:form id="mySampleForm">
    <h:selectOneMenu id="fileType" value="#{myMenuBean.filetype}">
         <f:selectItems value="#{myMenuBean.allFiletypes}" />
    </h:selectOneMenu>
    <h:commandButton type="submit" value="calc" action="ok" />
    </h:form>
    <HR>
    <h:outputText value="#{myMenuBean.filetype}"/>
    <HR>
    <h:messages />
    </f:view>
    </body>
    </html>
    faces-config.xml:
    <faces-config>
         <managed-bean>
              <managed-bean-name>myMenuBean</managed-bean-name>
              <managed-bean-class>MyMenuSample</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
         </managed-bean>
    </faces-config>
    MyMenuSample.java:
    import java.util.ArrayList;
    import java.util.Collection;
    import javax.faces.model.SelectItem;
    public class MyMenuSample {
        private String filetype;
        private ArrayList allFiletypes;
        public String getFiletype()
            return filetype;
        public void setFiletype(String s)
            filetype = s;
        public Collection getAllFiletypes()
            if(this.allFiletypes==null)
                 allFiletypes = new ArrayList();
                 allFiletypes.add(new SelectItem("type1"));
                 allFiletypes.add(new SelectItem("type2"));
                 allFiletypes.add(new SelectItem("type3"));
            return allFiletypes;
        public void setAllFiletypes(Collection list)
            allFiletypes = new ArrayList(list);
    }

  • JSF(2.1 & 2.2) upload problem Weblogic 12.1.1

    Hi all.
    I'm trying to configure an upload element with JSF, running on Weblogic 12.1.1.
    I tried this both with JSF 2.1 (custom component, custom filter) and the new h:inputFile tag in JSF 2.2
    And with both implementations I'm getting the same error from Weblogic: weblogic.servlet.utils.fileupload.SizeException: The field myElementId exceeds its maximum permitted  size of 0 characters
    I already found where the problem is coming from: Weblogic seems to ignore the max-file-size setting(part of the multipart-config tag) in the web.xml
    <servlet>
        <servlet-name>Faces Servlet</servlet-name>
        <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
       <multipart-config>
            <location>/tmp</location>
            <max-file-size>20848820</max-file-size>
            <max-request-size>418018841</max-request-size>
            <file-size-threshold>1048576</file-size-threshold>
          </multipart-config>
      </servlet>
    Without the <multipart-config> part, nothing happened when clicking the upload button. So Weblogic is using the multipart-config tag, but not the max-file-size tag.
    On Glashfish it all works fine. So the configuration seems to be OK. And the problem seems to be Weblogic related.
    Finally, to doublecheck, we modified the FacesServlet class (JSF 2.2, org.apache.myfaces 2.2.0-SNAPSHOT version) itself with the @MultipartConfig annotation
    @MultipartConfig(maxFileSize = 10485760L)
    public final class FacesServlet implements Servlet
    And this worked!
    so finally my question :-)
    How can I set the maxFileSize on Weblogic in a 'normal' way?  Am I missing something? Is there maybe a weblogic.xml setting for this?
    Thanks,
    Jorden

    problem seems to be solved by using the com,sun.faces 2.2.2 version

  • Jsf datatable inside datatable component rendering problem.

    I am creating an online survey application using JSF with IceFaces component library. The survey can have any number of questions. Each question can be any one of the types checkbox, radio button, etc with multiple options.
    For this, I am using a datatable to dynamically add a question to the survey. Inside that datatable, I am using another datatable to add option to the survey.
    Now the problem is, if I keep on click on add question button, in the outer data table, question is being added without any issue. Once I click on inner data table to add a option to any of the added questions, I am able to add. But after that, if I click again on add question button, it is not working.
    This is my xhtml code:
    <ice:dataTable id="icePnlQuestionAdd" var="questAdd" value="#{createSurveyManagedBean.surveyQuestionList}">
    <ice:column>
    <table border="0" cellspacing="0" cellpadding="0">
    <tr>
    <th><ice:outputText value="Question English" style="white-space: nowrap;" /></th>                                        
    <td colspan="15">                              
    <ice:inputText id="QuestionEn" style="width:485px;" value="#{questAdd.questionEn}" />
    </td>
    </tr>
    <tr>
    <ice:dataTable id="icePnlOptionAdd" var="optionAdd" value="#{questAdd.surveyQuestionOptionList}">                               <ice:column>
    <th><ice:outputText value="Option " /></th>
    <td><ice:inputText id="OptionEn" value="#{optionAdd.optionEn}" /></td>
    </ice:column>
    </ice:dataTable>
    </tr>
    </table>
    </ice:column>
    </ice:dataTable>
    This is the add question method:
    public String addQuestion() {
    SurveyDTO addSurveyQuestionDTO = new SurveyDTO();          
    questionNum = surveyQuestionList.size();          
    addSurveyQuestionDTO.setQuestionNum(questionNum);
    surveyQuestionList.add(addSurveyQuestionDTO);
    return "createSurvey";
    This is the add option method:
    public String addOption() {
    FacesContext context = FacesContext.getCurrentInstance();          
    if (context.getExternalContext().getRequestParameterMap().get("questionNum") != null) {
    String questionNum = (String) context.getExternalContext().getRequestParameterMap().get("questionNum");
    int selectedQuestionNum = Integer.valueOf(questionNum);                    
    SurveyQuestionOptionDTO surveyQuestionOptionDTO = new SurveyQuestionOptionDTO();
    surveyQuestionList.get(selectedQuestionNum).getSurveyQuestionOptionList().add(surveyQuestionOptionDTO);
    return "createSurvey";
    }

    Bind the h:datatable in the jsp to UIDataTable component in your java code. Then when the action method is invoked, use DataTable.getWrappedObject() to get the model. Cast the model to whatever your type is (List, Array...) and then iterate through the model to process individual rows.

  • JSF 2.0 faces-confix.xml problem

    Hi,
    I am developing web application using JSF2.0 along with netbean6.8 IDE. In this project, i use rich faces 3.3.2.
    when i run the application, it throws the following error
    deploy?path=C:\Documents and Settings\workplace\JSF3\build\web&name=JSF3&force=true failed on GlassFish v3 Domain
    C:\Documents and Settings\workplace\JSF3\nbproject\build-impl.xml:598: The module has not been deployed.
    BUILD FAILED (total time: 1 minute 9 seconds)
    When i remove faces-config.xml, it working fine.How to solve the problem.please help me.
    My project configurations,
    1. Glashfish v3 domain server
    2. jdk1.6
    3. Netbean 6.8 IDE
    4. JSF2.0
    5. richfaces jars
    richfaces-api-3.3.2.SR1.jar
    richfaces-impl-3.3.2.SR1.jar
    richfaces-ui-3.3.2.SR1.jar
    Thank in advance

    There must be a problem with your faces-config.xml file then.
    The full stacktrace (that you didn't post) probably mentions that.
    If you can't see the problem then post your faces-config.xml file.

  • SelectOneMenu problem

    Hi,
    I got the following setup:
    appBean.java
    =================
    private ArrayList country;
    public appBean() {
    this.country = new ArrayList();
    protected void init(){
    List list1 = this.getMiscService().getAllCountriesServ();
    for (i=0; i<list1.size(); i++) {
    Country co = (Country)list6.get(i);
    this.country.add(new SelectItem(Integer.toString(co.getId()), co.getName()));
    register.jsp
    ============================
    <h:selectOneMenu value="#{userBean.selectedCountry}" id="selectedCountry">
    <f:selectItems value="#{appBean.country}" id="countries"/>
    </h:selectOneMenu>
    <h:message for="selectedCountry" styleClass="errorMessage"/>
    userBean.java
    =======================
    private ArrayList selectedCountry;
    public ArrayList getSelectedCountry() {
         return this.selectedCountry;
    public void setSelectedCountry(ArrayList newSelectedCountry) {
         this.selectedCountry = newSelectedCountry;
    When I clicked on submit, I got an error msg beside the SelectOneMenu:
    " "selectedCountry": " Conversion Error setting value '1' for 'null Converter'.
    I hv even changed to :
    userBean.java
    =======================
    private SelectItem selectedCountry;
    public SelectItem getSelectedCountry() {
         return this.selectedCountry;
    public void setSelectedCountry(SelectItem newSelectedCountry) {
         this.selectedCountry = newSelectedCountry;
    but still get the same error msg. Pls help !!

    The "value" of your <h:selectOneMenu> isn't going to be the SelectItem instance itself. It'll be the "getValue()" result of the SelectItem, which is much more what you want in your model.
    So:
    For starters, change:
      this.country.add(new SelectItem(Integer.toString(co.getId()), co.getName()));to:
      this.country.add(new SelectItem(new Integer(co.getId()), co.getName()));unless you really want Strings. Then, change your selectedCountry code to:
    private int selectedCountry;
    public int getSelectedCountry() {
    return this.selectedCountry;
    public void setSelectedCountry(int newSelectedCountry) {
    this.selectedCountry = newSelectedCountry;
    }-- Adam Winer (EG member)

  • Upgrading from JSF 1.1 to JSF 1.2 (Mojarra)

    I am planning to upgrade my project from JSF 1.1 to JSF 1.2.
    My current configuration is:
    Sun JSF RI 1.1 configured with Ajax4JSF 1.1.0, tomahawk 1.1.6, WebLogic 10.3 and of course lot of dependent jar files eg: apache common libs, standard, etc.
    I am looking at two approaches to do this:
    1. Create a new project with JSF 1.2 and WebLogic 10.3 and start replicating the content from my old to the new project.
    2. Just upgrade the jsf related jar files in my existing project lib folder and try to get that to work.
    Not sure which one would be better. If someone can throw some light on this, would highly appreciate.
    Thanks
    SirG

    After all, the by you proposed first approach is somewhat odd. I would just backup it in flavor of a WAR file (if you did it all right, you should already have one).
    Upgrading is just matter of replacing the classes (JARs) and changing the configuration files. Upgrade at least web.xml to Servlet 2.5/JSP 2.1 and faces-config.xml to JSF 1.2. You may get deprecation warnings during compile, but that shouldn´t harm the functionality.

  • Converter and SelectOneMenu problem

    <h:selectOneMenu id="id_noofbeds" value="#{internals.numberofbeds}" converter="javax.faces.Integer">
    <f:selectItem itemValue="0" itemLabel="Studio" />
    <f:selectItem itemValue="1" itemLabel="1" />
    <f:selectItem itemValue="2" itemLabel="2" />
    <f:selectItem itemValue="3" itemLabel="3" />
    <f:selectItem itemValue="4" itemLabel="4" />
    <f:selectItem itemValue="5" itemLabel="5" />
    <f:selectItem itemValue="6" itemLabel="6" />
    <f:selectItem itemValue="7" itemLabel="7" />
    <f:selectItem itemValue="8" itemLabel="8+" />
    </h:selectOneMenu>
    I tried to run this code on my JSP page and have this in my backing bean:
    public Integer getNumberofbeds() {
    return numberofbeds;
    public void setNumberofbeds(Integer numberofbeds) {
    this.numberofbeds = numberofbeds;
    But when I run this code it always comes back with a validation error. I think it's because SelectOneMenu sends things back as a tuple, but not exactly sure how to handle it. Any help would be appreciated!!
    Tom

    See the javadoc of UISelectOne.validateValue(). It says:
    In addition to the standard validation behavior inherited from UIInput,
    ensure that any specified value is equal to one of the available options.
    If it is not, enqueue an error message and set the valid property to false.
    You specify the options as String literals using f:selectItem.
    So, the converted value which is type Integer is never equal to any of them.
    You can't use literal value of f:selectItem. Instead you may code as<f:selectItem itemValue="#{bean.option1}" itemLabel="1"/>Using f:selectItems may be better:<f:selectItems value="#{bean.options}"/>

  • JSF Problem Coding

    Hi, i am creating a web pages using JSF technology, I need some one help
    the code is
    <h:selectOneMenu rendered="#{chooselink.checkFullName}" value="#{chooselink.fullName}">
    <f:selectItems value="#{chooselink.namebean}"/>
    </h:selectOneMenu>
    problem is my code is working fine but it is very slow, it take a while to post the result, i did some hard coding, i add
    System.out.println(fullName); to the java bean, and i found out that if i choose one result in namebeam it will repeat it in
    I/0 as much as namebean has records,
    for example, in namebean has 1000 records and i choose one record from it, let say one record is omar, omar in I/0 will repeat 1000 times, that why my system is slowing down
    what should i do

    ok, i will try to explain my problem as specific as i can.
    JSF code is
    <h:selectOneMenu rendered="#{chooselink.checkFullName}" value="#{chooselink.fullName}">
    <f:selectItems value="#{chooselink.namebean}"/>
    </h:selectOneMenu>
    JAVA BEAN code is
    public String processFullName(){
    try {
    DriverManager.registerDriver(new oracle.jdbc.OracleDriver());
    url="jdbc:oracle:thin:@10.2.111.170:1521:testdb";
    conn = DriverManager.getConnection(url, "user","password");
    catch(Exception e){
    System.out.println("Driver not Found");
    try{
    String firstQuery;
    firstQuery = "select id_people peep33, first_nam || ' ' || Last_nam as fullname" +" ";
    firstQuery += "from people" +" ";
    firstQuery += "where first_nam || ' ' || Last_nam =" + "'" + fullName + "'" + " ";
    Statement stat = conn.createStatement();
    address = stat.executeQuery(firstQuery);
    while (address.next())
    idpeepfull = address.getInt("peep33");
    catch(Exception e){
    System.out.println("not working query ------processFullName.java");
    try { 
    String secondQuery;
    secondQuery ="select p.first_nam first, p.last_nam last, pp.man_num man, "+" ";
    secondQuery +="pc.pc_serial serial, pc.pc_model model, pc.pc_mac_add mac, d.dept deptt, pp.room_num room"+" ";
    secondQuery +="from people p, peep2pc pp, pcs pc, departments d, man_id_dept" +" ";
    secondQuery +="where p.id_people = pp.id_peep "+" ";
    secondQuery +="and pp.man_num = pc.man_num "+" ";
    secondQuery +="and pc.man_num = man_id_dept.man_num "+" ";
    secondQuery +="and d.id = man_id_dept.id_dept "+" ";
    secondQuery +="and p.id_people =" + idpeepfull + " ";
    Statement stat = conn.createStatement();
    address = stat.executeQuery(secondQuery);
    while(address.next())
    AllInventory.add(new FullInventory(address.getString("first"),address.getString("last"), address.getString("man"),
    address.getString("serial"), address.getString("model"), address.getString("mac"),
    address.getString("deptt"), address.getString("room")));
    String thirdQuery;
    thirdQuery ="select pm.id, pm.monitors_sn sn, pm.room_num room, m.monitors_name name " + " ";
    thirdQuery +="from peep2monitors pm, monitors m"+ " ";
    thirdQuery +="where pm.monitors_sn = m.monitors_ssn" + " ";
    thirdQuery +="and id = " + idpeepfull + " ";
    address = stat.executeQuery(thirdQuery);
    while(address.next())
    Monitors.add(new monitorInventory(address.getString("name"), address.getString("sn"), address.getString("room")));
    String fourthQuery;
    fourthQuery = "select pp.id_people people, pp.phone_extension ext, p.phone_mac_address address" + " ";
    fourthQuery +="from peep2phones pp, phones p" + " ";
    fourthQuery += " where pp.phone_extension = p.phone_extension" + " ";
    fourthQuery +="and pp.id_people = " + idpeepfull + " ";
    address = stat.executeQuery(fourthQuery);
    while (address.next())
    phones.add(new phoneInventory(address.getString("ext"),address.getString("address")));
    catch(Exception e){
    System.out.println("connection in chooseSearch.java is not working getSerialNum");
    try{
    conn.close();
    catch(Exception e){
    System.out.println("xxxxyx");
    // converting Collection to Array
    int numItems = AllInventory.size();
    int numMonitor = Monitors.size();
    int numPhone = phones.size();
    // create array static inside Array
    myInventory = new FullInventory[numItems];
    myMonitors = new monitorInventory[numMonitor];
    myphones = new phoneInventory[numPhone];
    numItems = 0;
    numMonitor = 0;
    numPhone = 0;
    for (FullInventory x: AllInventory){
    myInventory[numItems] = x;
    numItems ++;
    for (monitorInventory y : Monitors){
    myMonitors[numMonitor] = y;
    numMonitor ++;
    for (phoneInventory z: phones){
    myphones[numPhone] = z;
    numPhone ++;
    if (numItems == 0)
    showStudentTable = false;
    else
    showStudentTable = true;
    return " ";
    My problem is namebean records comes from sql statment, it has up to 1300 records, when i choose one of them and click it to store it into fullName, in I/O will repeat 1300 times, that's take too much time reloading,
    how can i fix that loop?

  • JSF problem on submit event

    Hi to everyone and sorry for my english,
    i've created a web form using jsf tecnology.
    This form contain 2 combo (selectOneMenu) one of this combo contain the region of Italy, so when an user select a region in this combo, on the second combo i'm load the city of this region, for make this i've an onChange event on the first combo this event meke a submit of form, i've also setted the property "immediate" = true.
    So when the first combo chenge value if i've in the form a inputText with property required = "true" the form show me the error message "field required", but i've set immediate = "true"?
    How i can bypass this problem.
    Thanxs a lot,
    Fabio.

    You should still use a value change listener. Putting db calls into your getters should be a last resort anyways. This is because JSF will call getters multiple times, thus causing you to make multiple DB calls.
    Plus, if you don't call renderResponse(), you're going to continue seeing your error message. Setting the immediate attribute doesn't necessarily skip the validation phase, rather, it processes validation in the Apply Request Values phase.
    Anyways, messing with the JSF phases can be a tricky concept for a newer person to understand. However, you should learn what you can about the standard JSF lifecycle.
    Getting to your problem at hand... The quick version is that you need to create a value change listener, attach it to the first combo box (region1), configure the value change listener to retrieve the appropriate values from DB, then set the second combo box (city1) options, and then call renderResponse().
    Here's some code to get you started.
    In your jsp:
    <h:selectOneMenu id="region1" value="#{userBean.selectedRegion1}"
        onchange="submit" immediate="true"
        valueChangeListener="#{userBean.regionSelected}">
    </h:selectOneMenu >In your UserBean class, create the following method:
         public void regionSelected(ValueChangeEvent event)
              throws AbortProcessingException {
              //Get the selected region from the event
              String region = (String)event.getNewValue();
              //Set the selected region in your bean
              setSelectedRegion(region);
              //Call DB to retrieve the city list for the selected region
              //Build Select Items list from record set
              //Set the city list with the new select items
              setCityList(newCityList);
              //Force to render response phase so that any error messages DO NOT get
              //displayed. i.e. Skip update model phase. Use immediate="true" on the
              //component that calls this valueChangeListener so that it does not
              //run any validation.
              FacesContext.getCurrentInstance().renderResponse();
         }That should get you good and started.
    CowKing

  • Getting problem in binding DropDown List with table data in visual JSF

    Hi All,
    I am new to visual JSF.
    I am getting few problems while working over components.
    I have succeeded in binding data of Person table in a drop down list .
    By just drag drop ..it worked.
    But while connecting to external DB this drag drop mechanism didn't work for me .
    1st problem that i faced was by dragging method columns are not visible when i did right click-> bind to Data -> DataProvider window .
    But i am successfully printed table Data in backend ie: by putting
    for(int i=0; i<xn_white_listDataProvider.getAllRows().length;i++){
           System.out.println("  value :"+xn_white_listDataProvider.getValue("SUB_ID",xn_white_listDataProvider.getRowKey(Integer.toString(i))));
    }I am not getting how to set Items in dropdown1
    I tried putting
    HelloSh.xn_white_listDataProvider.options['XNODE.XN_WHITE_LIST.SUB_ID, XNODE.XN_WHITE_LIST.SUB_ID'but it didn't work while for person data table
      items="#{HelloSh.personDataProvider.options['PERSON.PERSONID,PERSON.NAME']}"it is working
    when i am writting items="24,28" in dropdown1 box
    & printing its value in static text Like
    <webuijsf:staticText id="staticText3" style="position: absolute; left: 72px; top: 120px" text="#{HelloSh.dropDown1.items}"/> it is printing fine .
    Plz help me in this regard.
    Any clarification if needed plz let me know.
    Thanks in advance.

    <h:selectOneMenu id="menu1" styleClass="selectOneMenu">
    <f:selectItems value="*#{selectitems.pc_DynamicPortletEdit.regList}*" />
    </h:selectOneMenu>When we bind the list to the h:selectOneMenu the code in the JSP will be as given above.
    My doubts here are
    1) But when i tried to bind the list to a selectonemenu the code in the JSP is looking like this one
    <h:selectOneMenu id="menu1" styleClass="selectOneMenu">
    <f:selectItems value="*#{selectitems.pc_DynamicPortletEdit.regList.regList.toArray}*" />
    </h:selectOneMenu>2) Also in the runtime instead of displaying the values in the dropdown, i am getting the object names (javax.faces.model.SelectItem@680d0ccc) in the drop down.
    What am I doing wrong? Any help here would be usefull for me.
    BTW,
    the code in the backing bean for setting the values is like this
    List dropListValue = new ArrayList();
        for (int x=0; x<result.length; x++){ //where result is array of string values              
            SelectItem tempSelect = new SelectItem();
            tempSelect.setLabel(result[x]);
            tempSelect.setValue(result[x]);
            dropListValue.add(result[x]);                      
    this.setRegList(dropListValue );The bean is in request scope only.

  • Problem in JSF with Swing in a web application

    hi
    i am using jsf for my online projects.my problem is that when i use Swing concept ,the server is closed automatically when i click the swing dialog option 'OK', how can i protect server being closed automatically when user click the the options of Swing dialog box.it is so tedious because my application is going to integrate
    with online server?
    my swing java file is
    * FileExistsDialog.java
    package com.obs.ftw.util.alert;
    import java.awt.*;
    import java.awt.event.*;
    import java.awt.geom.Rectangle2D;
    import java.util.*;
    import javax.swing.*;
    import javax.swing.plaf.metal.MetalLookAndFeel;
    * FileExistsDialog: A JOptionPane-like dialog that displays the message
    * that a file exists.
    public class FileExistsDialog extends JDialog {
    * The component that gets the focus when the window is first opened
    private Component initialFocusOwner = null;
    * Command string for replace action (e.g., a button).
    * This string is never presented to the user and should
    * not be internationalized.
    private String CMD_REPLACE = "OK"/*NOI18N*/;
    * Command string for a cancel action (e.g., a button).
    * This string is never presented to the user and should
    * not be internationalized.
    private String CMD_CANCEL = "CANCEL"/*NOI18N*/;
    // Components we need to access after initialization
    private JButton replaceButton = null;
    private JButton cancelButton = null;
    public FileExistsDialog(){
         System.out.println("INSIDE THE FILE EXIST DIALOG");
         JFrame frame = new JFrame() {
         public Dimension getPreferredSize() {
         return new Dimension(200,100);
         frame.setTitle("Debugging frame");
         frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
         frame.pack();
         frame.setVisible(false);
    FileExistsDialog dialog = new FileExistsDialog(frame, true);
         dialog.addWindowListener(new WindowAdapter() {
         public void windowClosing(WindowEvent event) {
         System.exit(0);
         public void windowClosed(WindowEvent event) {
         System.exit(0);
         dialog.pack();
         dialog.setVisible(true);
    * Creates a new FileExistsDialog
    * @param parent parent frame
    * @param modal modal flag
    public FileExistsDialog(Frame parent,boolean modal) {
    super(parent, modal);
         //initResources();
         System.out.println("INSIDE THE FILE EXIST DIALOG CONSTRUCTOR");
    initComponents();
    pack();
    * Determines the locale, loads resources
    /* public void initResources() {
         Locale locale = Locale.getDefault();
    resources = ResourceBundle.getBundle(
              "samples.resources.bundles.FileExistsDialogResources", locale);
    imagePath = resources.getString("images.path");
    }*/ // initResources()
    * Sets all of the buttons to be the same size. This is done
    * dynamically after the buttons are created, so that the layout
    * automatically adjusts to the locale-specific strings.
    private void equalizeButtonSizes() {
         System.out.println("INSIDE THE equalizeButtonSizes()");
    String[] labels = new String[] {
    replaceButton.getText(),
         cancelButton.getText()
         // Get the largest width and height
         Dimension maxSize= new Dimension(0,0);
         Rectangle2D textBounds = null;
         Dimension textSize = null;
    FontMetrics metrics =
              replaceButton.getFontMetrics(replaceButton.getFont());
         Graphics g = getGraphics();
         for (int i = 0; i < labels.length; ++i) {
         textBounds = metrics.getStringBounds(labels, g);
         maxSize.width =
         Math.max(maxSize.width, (int)textBounds.getWidth());
         maxSize.height =
         Math.max(maxSize.height, (int)textBounds.getHeight());
    Insets insets =
         replaceButton.getBorder().getBorderInsets(replaceButton);
    maxSize.width += insets.left + insets.right;
    maxSize.height += insets.top + insets.bottom;
    // reset preferred and maximum size since BoxLayout takes both
         // into account
    replaceButton.setPreferredSize((Dimension)maxSize.clone());
    cancelButton.setPreferredSize((Dimension)maxSize.clone());
    replaceButton.setMaximumSize((Dimension)maxSize.clone());
    cancelButton.setMaximumSize((Dimension)maxSize.clone());
    } // equalizeButtonSizes()
    * This method is called from within the constructor to
    * initialize the dialog.
    private void initComponents() {
         System.out.println("INSIDE THE initComponents()");
         // Configure the window, itself
    Container contents = getContentPane();
    contents.setLayout(new GridBagLayout ());
    GridBagConstraints constraints = null;
    setTitle("Waring");
         // accessibility - all applets, frames, and dialogs should
         // have descriptions
         this.getAccessibleContext().setAccessibleDescription("Descriptions");
         addWindowListener(new WindowAdapter() {
         public void windowOpened(WindowEvent event) {
              // For some reason the window opens with no focus owner,
              // so we need to force the issue
         if (initialFocusOwner != null) {
              initialFocusOwner.requestFocus();
              // Only do this the 1st time the window is opened
              initialFocusOwner = null;
         public void windowClosing(WindowEvent event) {
         System.out.println("INSIDE THE windowClosing");     
         // Treat it like a cancel
              windowAction(CMD_CANCEL);
         // image
    JLabel imageLabel = new JLabel();
    imageLabel.setIcon(
    new ImageIcon("/images/degraded_large.gif"));
    // accessibility - set name so that low vision users get a description
    imageLabel.getAccessibleContext().setAccessibleName("OK");
    constraints = new GridBagConstraints ();
    constraints.gridheight = 2;
    constraints.insets = new Insets(12, 33, 0, 0);
    constraints.anchor = GridBagConstraints.NORTHEAST;
    contents.add(imageLabel, constraints);
    // header
    JLabel headerLabel = new JLabel ();
    headerLabel.setText("SAMPLE");
    headerLabel.setForeground(
         new Color(MetalLookAndFeel.getBlack().getRGB()));
    constraints = new GridBagConstraints ();
    constraints.insets = new Insets(12, 12, 0, 11);
    constraints.anchor = GridBagConstraints.WEST;
    contents.add(headerLabel, constraints);
         // Actual text of the message
         JTextArea contentTextArea = new JTextArea();
    contentTextArea.setEditable(false);
    contentTextArea.setText("SAMPLE");
    contentTextArea.setBackground(
              new Color(MetalLookAndFeel.getControl().getRGB()));
    // accessibility -- every component that can have the
         // keyboard focus must have a name. This text area has no
         // label, so the name must be set explicitly (if it had a
         // label, the name would be pulled from the label).
    contentTextArea.getAccessibleContext().setAccessibleName(
              "CONTENTNAME");
    constraints = new GridBagConstraints ();
    constraints.gridx = 1;
    constraints.gridy = 1;
    constraints.insets = new Insets(0, 12, 0, 11);
    constraints.anchor = GridBagConstraints.WEST;
    contents.add(contentTextArea, constraints);
         // Buttons
         JPanel buttonPanel = new JPanel();
    buttonPanel.setLayout (new BoxLayout(buttonPanel, 0));
         replaceButton = new JButton();
         replaceButton.setActionCommand(CMD_REPLACE);
    replaceButton.setText("OK");
    replaceButton.setToolTipText("TO OK");
         replaceButton.addActionListener(new ActionListener() {
         public void actionPerformed(ActionEvent event) {
         windowAction(event);
    buttonPanel.add(replaceButton);
    // spacing
    buttonPanel.add(Box.createRigidArea(new Dimension(5,0)));
         cancelButton = new JButton();
         cancelButton.setActionCommand(CMD_CANCEL);
    cancelButton.setText("CANCEL");
    cancelButton.setNextFocusableComponent(replaceButton);
         cancelButton.setToolTipText("TO CANCEL");
         cancelButton.addActionListener(new ActionListener() {
         public void actionPerformed(ActionEvent event) {
         windowAction(event);
    buttonPanel.add(cancelButton);
    constraints = new GridBagConstraints ();
    constraints.gridx = 1;
    constraints.gridy = 2;
    constraints.insets = new Insets(12, 12, 11, 11);
    constraints.anchor = GridBagConstraints.WEST;
    contents.add(buttonPanel, constraints);
         // Equalize the sizes of all the buttons
         equalizeButtonSizes();
         // For some reason, the dialog appears with no input focus.
         // We added a window listener above to force the issue
         initialFocusOwner = replaceButton;
    } // initComponents()
    * The user has selected an option. Here we close and dispose the dialog.
    * If actionCommand is an ActionEvent, getCommandString() is called,
    * otherwise toString() is used to get the action command.
    * @param actionCommand may be null
    private void windowAction(Object actionCommand) {
         System.out.println("INSIDE THE WINDOW ACTION");
         String cmd = null;
    if (actionCommand != null) {
         if (actionCommand instanceof ActionEvent) {
         cmd = ((ActionEvent)actionCommand).getActionCommand();
         } else {
         cmd = actionCommand.toString();
         if (cmd == null) {
         // do nothing
         } else if (cmd.equals(CMD_REPLACE)) {
         System.out.println("your replace code here...");
         } else if (cmd.equals(CMD_CANCEL)) {
         System.out.println("your cancel code here...");
         setVisible(false);
         dispose();
    } // windowAction()
    * This main() is provided for debugging purposes, to display a
    * sample dialog.
    // main()
    } // class FileExistsDialog
    and calling java function is
    public String fileDialog(){
         return "Success";
    public void processFile(ActionEvent event){
         System.out.println("INSIDE THE FILE DIALOG");
         FileExistsDialog file     = new FileExistsDialog();
         System.out.println("SUCCESS");
    called from
         <h:commandButton action="#{userLogin.fileDialog}" actionListener="#{userLogin.processFile}"></h:commandButton>
    pls help me as soon
    advance thanks
    rgds
    oasisdeserts

    Swing is GUI library for use in desktop applications.
    JSF is a web application framework which runs on an application server and is accessed by clients via web browsers.
    To fully understand what you have done, try accessing your application from a different machine than the server.
    To answer your question, don't invoke System.exit() if you would like the process to continue. But that is the least of your problems.

  • User athentication problem in jsf

    Hi all,
    Upto to now i used filters for user authentication by placing the protected pages in the folder from the remaining the pages which are on root. The filter will come into action by the url detection of the foldername. But actually my problem here is different I should not have to place in separate folders and have to provide authentication for particular files which are in sample root. This is I used to solve in normal jsp programming with the help of session. But whereareas in JSF how cleanly to solve this problem. Also iam new to JSF. Please any help regarding this. I am at urgent for the solution.
    many thanks,
    vijaycanaan
    Message was edited by:
    vijaycanaan

    Required help regarding this topic please.

Maybe you are looking for