Link to home
Create AccountLog in
Avatar of sigma19
sigma19Flag for United States of America

asked on

Rich Faces

In my login page , when I click LOGIN , the validation should be done and also a modalpanel should be opened if the user enters correct username and password. But in my case , the validation is done ,but the ModalPanel is not opening.
<rich:panel header="User Login">
										<TABLE WIDTH="100%" CELLPADDING="5" CELLSPACING="0">
											
											<TR>
												<TD ALIGN=RIGHT NOWRAP><b><font COLOR="#0F218B">User ID:</font></b></TD>
												<TD><h:inputText size="15" value="#{loginbean.userid}"/></TD>
											</TR>
											<TR>
												<TD ALIGN=RIGHT NOWRAP><b><font COLOR="#0F218B">Password:</font></b></TD>
												<TD><h:inputSecret  size="15" value="#{loginbean.password}"/></TD>
											</TR>
											<TR>
												<TD ALIGN=CENTER COLSPAN="2">
												
												<a4j:commandButton value="Login" action="#{loginbean.validate}" reRender="result,mp"
                                                  onmouseover="this.style.color='#d30100'"  onmouseout="this.style.color='#ffffff'" style="background:url(images/toolbar-Menu-Back.gif) repeat-x;border:1px solid #5f8cc3;color:#ffffff"
                                                  oncomplete="Richfaces.showModalPanel('storerForm:mp',{top:320,left:450});" />
												
												</TD>
											</TR>
										</TABLE>									
									</rich:panel></div>						
								
						</TD></TR>
				</TABLE></div>
		
				<P><HR SIZE="2" WIDTH="700"></HR>
				<P align = center>2008 &copy; Copyright Kintetsu World Express, Inc. All rights reserved. 
				
				</TR>
				
			</TABLE>
		</div>
		</TD>
		</TR>
		</TABLE>
		</div>	
			</div>
			</div>
   	 	
<div id="bottom"  class="mainbottom">		
</div>
</h:form>
			<h:form id="storerForm">
				<rich:modalPanel  id="mp" height="180" width="230" moveable="true"  zindex="1" left="5" top="5" styleClass="rich-mpnl-text">
                    <f:facet name="header">
                     <h:outputText value=" Please Select Warehouse  /  Storer" />
                     </f:facet>
                      <f:facet name="controls">
                      <h:graphicImage value="/images/close.png" style="cursor:pointer" onclick="Richfaces.hideModalPanel('mp')" />
                     </f:facet>
                      <b> Warehouse</b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b> Storer </b>
                   <rich:scrollableDataTable width="230px" height="80px" rows="7"  
                   value="#{WareHouseBean.warID}" var="category">
                      <rich:column id="wareHouseID" width="100">
						<f:facet name="header"><h:outputText styleClass="headerText" value="Warehouse" /></f:facet>
						<h:outputText value="#{category.wareHouseID}" />
					</rich:column>
					<rich:column id="storerkey" width="110">
						<f:facet name="header"><h:outputText styleClass="headerText" value="Storer" /></f:facet>
						<h:outputText value="#{category.storerkey}" />
					</rich:column>		
                  </rich:scrollableDataTable>  
			 			<br></br>
			 			&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
			 			<a4j:commandButton value="Select"  reRender="mp"  />                        
        
                  </rich:modalPanel>

Open in new window

Avatar of Bart Cremers
Bart Cremers
Flag of Belgium image

Could you post the entire JSP? Or a mockup showing the problem.
Avatar of sigma19

ASKER

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
      "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>


      
<HTML>
<HEAD>
        <link rel="stylesheet" type="text/css" href="styles/common.css" />
            
            <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
            <meta http-equiv="Refresh" content="300"/>
<TITLE>KWE Unified Warehouse System</TITLE>

<STYLE>
      BODY {
            background-color:#FFFFFF;
            font-family:Verdana;
            font-size:8pt;
            color:#0F218B;
            margin:0px;
      }
      INPUT{
            font-family:Verdana;
            font-size:8pt;
      }
      INPUT.inp{
            border:1px solid #999999;
            color:#333333;
            background-color:#ffffff;
      }
      INPUT.btn{
            border:1px solid #ff8833;
            color:white;
            font-weight:bold;
            background-color:#ff8833;
      }
      TD{
            font-family:Verdana;
            font-size:8pt;
      }
      TD.radio{

            font-size:7.5pt;
            font-weight:bold;
      }
      TD.sun{
            color:#ff0000
            font-family:Verdana, Arial, Helvetica, sans-serif;
            font-size:8pt;
      }
      TD.scv{
            color:#ffffff;
            background-color:#ff6633;
            font-size:7pt;
            font-weight:bold;
            text-align:center;
            padding-left:15px;
            padding-right:15px;
            width:136px;
      }
      TD.scc{
            color:#ffffff;
            background-color:#ff8833;
            font-size:7pt;
            font-weight:bold;
            text-align:center;
            padding-left:15px;
            padding-right:15px;
            width:136px;
      }
      TD.sce{
            color:#ffffff;
            background-color:#ffaa33;
            font-size:7pt;
            font-weight:bold;
            text-align:center;
            padding-left:15px;
            padding-right:15px;
            width:136px;
      }
      TD.sco{
            color:#ffffff;
            background-color:#ffcc33;
            font-size:7pt;
            font-weight:bold;
            text-align:center;
            padding-left:15px;
            padding-right:15px;
            width:136px;
      }
      .rich-mpnl-body{
       background-color:#bed6f8;
      }
      
      A{text-decoration:none;}
      A:link{color:#FF0000;}
      A:active{color:#FF0000;}
      A:visited{color:#FF0000;}
      A:hover{color:#FF0000;text-decoration:underline;}
      
      A.chPwd{text-decoration:underline;}
      A.chPwd:link{color:#FF0000;text-decoration:underline;}
      A.chPwd:active{color:#FF0000;text-decoration:underline;}
      A.chPwd:visited{color:#FF0000;text-decoration:underline;}
      A.chPwd:hover{color:#CC0000;text-decoration:underline;}      
      TD.name{
            font-family:Arial;
            font-size:10pt;
            font-style:Italic;
            font-weight:bold;
            color:#003C9C;
            padding-bottom:1px;
      }
.rich-panel-header{
      background:transparent url(images/toolbar-Menu-Back.gif);color: #FFFFFF;
}  
</STYLE>


</HEAD>

<BODY>
            
            <f:view>
                  <h:form>
        <div id="top"  class="maintop" ></div>      
        <div id="main"  class="maincontainer">
            <div style="position:absolute;float: left; padding: 55px 0 0 175px;"><img src="images/KWE-logo.gif" border="0" alt="Kintetsu World Express"></div>
          <div style="position:absolute;float: left; padding: 75px 0 0 265px;"><font size="2.5pt"><b><i><font color="red">U</font><font color="#00008B">nified</font> <font color="red">W</font><font color="#00008B">arehouse</font> <font color="red">S</font><font color="#00008B">ystem</font></i></b></font></div>
          <div style="position:absolute;float: left; padding: 75px 0 0 755px;">Version 2.0</div>

            <div id="menu" class="container">
            <rich:spacer height="90"></rich:spacer>
              <div class="trans">
            <TABLE border="0" cellpadding="0" cellspacing="0" width="100%" height="100%">
            
            <TR>
            <TD align="center">
            <div class="trans">
            <TABLE border="0" cellpadding="0" cellspacing="0">
                  <TR><TD>
                        <div class="trans">
                        <TABLE align="left">
                        <TR>
                              
                        </TR>
                        </TABLE>
                      </div>                  
                  </TD>
                  </TR>
            
            <div class="trans">
            <TR>
            <TD>
            <TABLE border="0" cellpadding="0" cellspacing="0">
            <TR>
            <TD>
            <div class="trans">
            <TABLE border="0" cellpadding="0" cellspacing="0">
            <TR><TD class="scv" style="padding-top:25px;">WAREHOUSE</td>
            <TR><TD class="scv" style="padding-bottom:10px;">MANAGEMENT</td>
            </TR>
            </TABLE></div>
            </TD>
            
            
            <TD align="center">
            <div class="trans">
            <TABLE border="0" cellpadding="0" cellspacing="0">
            <TR><TD class="scc" style="padding-top:25px;">ASSET</td></tr>
            <TR><TD class="scc" style="padding-bottom:10px;">MANAGEMENT</td></tr>
            </TABLE></div>
            </TD>
            
            
            <TD align="center">
            <div class="trans">
            <TABLE border="0" cellpadding="0" cellspacing="0">
            <TR><TD class="sce" style="padding-top:25px;">RF</td></tr>
            <TR><TD class="sce" style="padding-bottom:10px;">PROCESSING</td></tr>
            </TABLE></div>
            </TD>
            
            
            <TD ALIGN="right">
            <div class="trans">
            <TABLE border="0" cellpadding="0" cellspacing="0">
            <TR><TD class="sco" style="padding-top:25px;">INVENTORY</td></tr>
            <TR><TD class="sco" style="padding-bottom:10px;">REPORTING</td></tr>
            </TABLE></div>
            </TD>
            </TR>
            </TABLE>
            </TD>
            </TR>
            
            
            <TR>
            <TD style="padding-bottom:20px;">
            <embed src="flash/kwe.swf" TYPE="application/x-shockwave-flash" width="100%" height="135" quality="high" loop="true" pluginspace="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">
            <!-- jwms.swf -->
            </TD>
            </TR>
            
            <TR><TD align=center><h:outputText value="#{loginbean.errMessage}" id="result" style="font-weight:600;color:red"/></TD></TR>
            </TABLE>
            
       <div class="trans">
            <TABLE WIDTH="100%" HEIGHT="100%" CELLPADDING="0" CELLSPACING="0">
            <TR align="center">
              <div class="trans">      
                        <TABLE BORDER="0" CELLPADDING="5" align="center">
                              <TR align="center">
                                    <TD WIDTH="250" VALIGN="TOP" align="center">
                                                      <div class="trans">
                                                      <rich:panel header="User Login">
                                                            <TABLE WIDTH="100%" CELLPADDING="5" CELLSPACING="0">
                                                                  
                                                                  <TR>
                                                                        <TD ALIGN=RIGHT NOWRAP><b><font COLOR="#0F218B">User ID:</font></b></TD>
                                                                        <TD><h:inputText size="15" value="#{loginbean.userid}"/></TD>
                                                                  </TR>
                                                                  <TR>
                                                                        <TD ALIGN=RIGHT NOWRAP><b><font COLOR="#0F218B">Password:</font></b></TD>
                                                                        <TD><h:inputSecret  size="15" value="#{loginbean.password}"/></TD>
                                                                  </TR>
                                                                  <TR>
                                                                        <TD ALIGN=CENTER COLSPAN="2">
                                                                        
                                                                        <a4j:commandButton value="Login"
                                                  onmouseover="this.style.color='#d30100'"  onmouseout="this.style.color='#ffffff'" style="background:url(images/toolbar-Menu-Back.gif) repeat-x;border:1px solid #5f8cc3;color:#ffffff"
                                                  onclick="Richfaces.showModalPanel('storerForm:mp',{top:320,left:450});" />
                                                                        
                                                                        </TD>
                                                                  </TR>
                                                            </TABLE>                                                      
                                                      </rich:panel></div>                                    
                                                
                                    </TD></TR>
                        </TABLE></div>
            
                        <P><HR SIZE="2" WIDTH="700"></HR>
                        <P align = center>2008 &copy; Copyright Kintetsu World Express, Inc. All rights reserved.
                        
                        </TR>
                        
                  </TABLE>
            </div>
            </TD>
            </TR>
            </TABLE>
            </div>      
                  </div>
                  </div>
                
<div id="bottom"  class="mainbottom">            
</div>
</h:form>
                  <h:form id="storerForm">
                        <rich:modalPanel  id="mp" height="180" width="230" moveable="true"  zindex="1" left="5" top="5" styleClass="rich-mpnl-text">
                    <f:facet name="header">
                     <h:outputText value=" Please Select Warehouse  /  Storer" />
                     </f:facet>
                      <f:facet name="controls">
                      <h:graphicImage value="/images/close.png" style="cursor:pointer" onclick="Richfaces.hideModalPanel('mp')" />
                     </f:facet>
                      <b> Warehouse</b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b> Storer </b>
                   <rich:scrollableDataTable width="230px" height="80px" rows="7"  
                   value="#{WareHouseBean.warID}" var="category">
                      <rich:column id="wareHouseID" width="100">
                                    <f:facet name="header"><h:outputText styleClass="headerText" value="Warehouse" /></f:facet>
                                    <h:outputText value="#{category.wareHouseID}" />
                              </rich:column>
                              <rich:column id="storerkey" width="110">
                                    <f:facet name="header"><h:outputText styleClass="headerText" value="Storer" /></f:facet>
                                    <h:outputText value="#{category.storerkey}" />
                              </rich:column>            
                  </rich:scrollableDataTable>  
                                     <br></br>
                                     &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                                     <a4j:commandButton value="Select" action="#{loginbean.validate}" reRender="result,mp"  />                        
       
                  </rich:modalPanel>
                         
                        </h:form>

</f:view>

</BODY>

</HTML>


What exactly is not working?

I've deployed the page on my local Tomcat server (wrote a fake loginbean for it) and it works for me. When I click login, a modal panel pops up showing a table.

Is it showing any errors when you perform the action?
Avatar of sigma19

ASKER

The Validation should be done before opening the modalpanel ,i.e if user enters wrong password,it should show error message only. In my case it is showing error message and opening modalpanel too.The ModalPanel should not open if the user enters wrong password. please see my latest code. I made some changes.
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>
<%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
 
 
	
<HTML>
<HEAD>
        <link rel="stylesheet" type="text/css" href="styles/common.css" />
		
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<TITLE>KWE Unified Warehouse System</TITLE>
 
<STYLE>
	BODY {
		background-color:#FFFFFF;
		font-family:Verdana;
		font-size:8pt;
		color:#0F218B;
		margin:0px;
	}
	INPUT{
		font-family:Verdana;
		font-size:8pt;
	}
	INPUT.inp{
		border:1px solid #999999;
		color:#333333;
		background-color:#ffffff;
	}
	INPUT.btn{
		border:1px solid #ff8833;
		color:white;
		font-weight:bold;
		background-color:#ff8833;
	}
	TD{
		font-family:Verdana;
		font-size:8pt;
	}
	TD.radio{
 
		font-size:7.5pt;
		font-weight:bold;
	}
	TD.sun{
		color:#ff0000
		font-family:Verdana, Arial, Helvetica, sans-serif;
		font-size:8pt;
	}
	TD.scv{
		color:#ffffff;
		background-color:#ff6633;
		font-size:7pt;
		font-weight:bold;
		text-align:center;
		padding-left:15px;
		padding-right:15px;
		width:136px;
	}
	TD.scc{
		color:#ffffff;
		background-color:#ff8833;
		font-size:7pt;
		font-weight:bold;
		text-align:center;
		padding-left:15px;
		padding-right:15px;
		width:136px;
	}
	TD.sce{
		color:#ffffff;
		background-color:#ffaa33;
		font-size:7pt;
		font-weight:bold;
		text-align:center;
		padding-left:15px;
		padding-right:15px;
		width:136px;
	}
	TD.sco{
		color:#ffffff;
		background-color:#ffcc33;
		font-size:7pt;
		font-weight:bold;
		text-align:center;
		padding-left:15px;
		padding-right:15px;
		width:136px;
	}
	.rich-mpnl-body{
	 background-color:#bed6f8; 
	}
	
	A{text-decoration:none;}
	A:link{color:#FF0000;}
	A:active{color:#FF0000;}
	A:visited{color:#FF0000;}
	A:hover{color:#FF0000;text-decoration:underline;}
	
	A.chPwd{text-decoration:underline;}
	A.chPwd:link{color:#FF0000;text-decoration:underline;}
	A.chPwd:active{color:#FF0000;text-decoration:underline;}
	A.chPwd:visited{color:#FF0000;text-decoration:underline;}
	A.chPwd:hover{color:#CC0000;text-decoration:underline;}	
	TD.name{
		font-family:Arial;
		font-size:10pt;
		font-style:Italic;
		font-weight:bold;
		color:#003C9C;
		padding-bottom:1px;
	}
.rich-panel-header{
      background:transparent url(images/toolbar-Menu-Back.gif);color: #FFFFFF;
}   
</STYLE>
 
 
</HEAD>
 
<BODY>
		
		<f:view>
			<h:form>
        <div id="top"  class="maintop" ></div>	
        <div id="main"  class="maincontainer">
	      <div style="position:absolute;float: left; padding: 55px 0 0 175px;"><img src="images/KWE-logo.gif" border="0" alt="Kintetsu World Express"></div>
          <div style="position:absolute;float: left; padding: 75px 0 0 265px;"><font size="2.5pt"><b><i><font color="red">U</font><font color="#00008B">nified</font> <font color="red">W</font><font color="#00008B">arehouse</font> <font color="red">S</font><font color="#00008B">ystem</font></i></b></font></div>
          <div style="position:absolute;float: left; padding: 75px 0 0 755px;">Version 2.0</div>
 
		<div id="menu" class="container">
		<rich:spacer height="90"></rich:spacer>
  		<div class="trans"> 
		<TABLE border="0" cellpadding="0" cellspacing="0" width="100%" height="100%">
		
		<TR>
		<TD align="center">
		<div class="trans">
		<TABLE border="0" cellpadding="0" cellspacing="0">
			<TR><TD>
				<div class="trans">
				<TABLE align="left">
				<TR>
					
				</TR>
				</TABLE>
			    </div>			
			</TD>
			</TR>
		
		<div class="trans">
		<TR>
		<TD>
		<TABLE border="0" cellpadding="0" cellspacing="0">
		<TR>
		<TD>
		<div class="trans">
		<TABLE border="0" cellpadding="0" cellspacing="0">
		<TR><TD class="scv" style="padding-top:25px;">WAREHOUSE</td>
		<TR><TD class="scv" style="padding-bottom:10px;">MANAGEMENT</td>
		</TR>
		</TABLE></div>
		</TD>
		
		
		<TD align="center">
		<div class="trans">
		<TABLE border="0" cellpadding="0" cellspacing="0">
		<TR><TD class="scc" style="padding-top:25px;">ASSET</td></tr>
		<TR><TD class="scc" style="padding-bottom:10px;">MANAGEMENT</td></tr>
		</TABLE></div>
		</TD>
		
		
		<TD align="center">
		<div class="trans">
		<TABLE border="0" cellpadding="0" cellspacing="0">
		<TR><TD class="sce" style="padding-top:25px;">RF</td></tr>
		<TR><TD class="sce" style="padding-bottom:10px;">PROCESSING</td></tr>
		</TABLE></div>
		</TD>
		
		
		<TD ALIGN="right">
		<div class="trans">
		<TABLE border="0" cellpadding="0" cellspacing="0">
		<TR><TD class="sco" style="padding-top:25px;">INVENTORY</td></tr>
		<TR><TD class="sco" style="padding-bottom:10px;">REPORTING</td></tr>
		</TABLE></div>
		</TD>
		</TR>
		</TABLE>
		</TD>
		</TR>
		
		
		<TR>
		<TD style="padding-bottom:20px;">
		<embed src="flash/kwe.swf" TYPE="application/x-shockwave-flash" width="100%" height="135" quality="high" loop="true" pluginspace="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">
		<!-- jwms.swf -->
		</TD>
		</TR>
		
		<TR><TD align=center><h:outputText value="#{loginbean.errMessage}" id="result" style="font-weight:600;color:red"/></TD></TR>
		</TABLE>
		
       <div class="trans">
		<TABLE WIDTH="100%" HEIGHT="100%" CELLPADDING="0" CELLSPACING="0">
		<TR align="center">
		  <div class="trans">	
				<TABLE BORDER="0" CELLPADDING="5" align="center">
					<TR align="center">
						<TD WIDTH="250" VALIGN="TOP" align="center">
									<div class="trans">
									<rich:panel header="User Login">
										<TABLE WIDTH="100%" CELLPADDING="5" CELLSPACING="0">
											
											<TR>
												<TD ALIGN=RIGHT NOWRAP><b><font COLOR="#0F218B">User ID:</font></b></TD>
												<TD><h:inputText size="15" value="#{loginbean.userid}"/></TD>
											</TR>
											<TR>
												<TD ALIGN=RIGHT NOWRAP><b><font COLOR="#0F218B">Password:</font></b></TD>
												<TD><h:inputSecret  size="15" value="#{loginbean.password}"/></TD>
											</TR>
											<TR>
												<TD ALIGN=CENTER COLSPAN="2">
												
												<a4j:commandButton value="Login"  action="#{loginbean.validate}" reRender="result,mp"
                                                  onmouseover="this.style.color='#d30100'"  onmouseout="this.style.color='#ffffff'" style="background:url(images/toolbar-Menu-Back.gif) repeat-x;border:1px solid #5f8cc3;color:#ffffff"
                                                  oncomplete="Richfaces.showModalPanel('storerForm:mp',{top:320,left:450});" />
												
												</TD>
											</TR>
										</TABLE>									
									</rich:panel></div>						
								
						</TD></TR>
				</TABLE></div>
		
				<P><HR SIZE="2" WIDTH="700"></HR>
				<P align = center>2008 &copy; Copyright Kintetsu World Express, Inc. All rights reserved. 
				
				</TR>
				
			</TABLE>
		</div>
		</TD>
		</TR>
		</TABLE>
		</div>	
			</div>
			</div>
   	 	
<div id="bottom"  class="mainbottom">		
</div>
</h:form>
			<h:form id="storerForm">
				<rich:modalPanel  id="mp" height="180" width="230" moveable="true"  zindex="1" left="5" top="5" styleClass="rich-mpnl-text">
                    <f:facet name="header">
                     <h:outputText value=" Please Select Warehouse  /  Storer" />
                     </f:facet>
                      <f:facet name="controls">
                      <h:graphicImage value="/images/close.png" style="cursor:pointer" onclick="Richfaces.hideModalPanel('mp')" />
                     </f:facet>
                      <b> Warehouse</b>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b> Storer </b>
                   <rich:scrollableDataTable width="230px" height="80px" rows="7"  
                   value="#{WareHouseBean.warID}" var="category">
                      <rich:column id="wareHouseID" width="100">
						<f:facet name="header"><h:outputText styleClass="headerText" value="Warehouse" /></f:facet>
						<h:outputText value="#{category.wareHouseID}" />
					</rich:column>
					<rich:column id="storerkey" width="110">
						<f:facet name="header"><h:outputText styleClass="headerText" value="Storer" /></f:facet>
						<h:outputText value="#{category.storerkey}" />
					</rich:column>		
                  </rich:scrollableDataTable>  
			 			<br></br>
			 			&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
			 			<a4j:commandButton value="Select"  />                        
        
                  </rich:modalPanel>
 				
				</h:form>
 
</f:view>
 
</BODY>
 
</HTML>

Open in new window

Could you show me your validate() method?
Avatar of sigma19

ASKER

Now I am having another problem with the modalpanel. I kept this same modalpanel in another page, the problem is I can see the modalpanel but scrollabledata table inside it is not appearing. Could you help in this case.
I would first like to post some general comments about the jsp. It is not generating a well-structured HTML page. You've got some divs in there which are not closed. That makes it hard to read the code.

For the scrollabledata problem it's hard to help without the code for the backingbeans.
Avatar of sigma19

ASKER

Thanks for your comments. I closed all the divs. My scrollabledatatable backing beans are as follows:


WareHouse.java:
package com.kwe.uws.web.login;
 
public class WareHouse {
 
	private String WareHouseID;
    private String Storerkey;
	
       public WareHouse() {
    	WareHouseID = "";
   		Storerkey = "";
   	}
   	
       public WareHouse(String wareHouseID, String storerkey) {
		super();
		WareHouseID = wareHouseID;
		Storerkey = storerkey;
	}
 
	public String getWareHouseID() {
   		return WareHouseID;
   	}
 
   	public void setWareHouseID(String wareHouseID) {
   		WareHouseID = wareHouseID;
   	}
 
   	public String getStorerkey() {
   		return Storerkey;
   	}
 
   	public void setStorerkey(String storerkey) {
   		Storerkey = storerkey;
   	}
       
	
	
}
 
WareHouseBean.java:
package com.kwe.uws.web.login;
 
 
public class WareHouseBean {
     
	     private WareHouse[] warID = new WareHouse[7];
	     
	     public WareHouse[] getWarID() {
	 		return warID;
	 	}
	     public void setWarID(WareHouse[] warID) {
	 		this.warID = warID;
	 	}
       public WareHouseBean(){
    	   System.out.println("test");
    	   warID[0] = new WareHouse("100002","DAISO");
    	   warID[1] = new WareHouse("100002","OPI");
    	   warID[2] = new WareHouse("100002","NESCAFE");
    	   warID[3] = new WareHouse("100002","APPLE");
    	   warID[4] = new WareHouse("100002","GROCERY");
    	   warID[5] = new WareHouse("100002","APPAREL");
    	   warID[6] = new WareHouse("100002","APPAREL");
    	   
    	   
    	   
       }
       public String test(){
    	   System.out.println("Method Invoked");
    	   return null;
       }
 
}

Open in new window

ASKER CERTIFIED SOLUTION
Avatar of Bart Cremers
Bart Cremers
Flag of Belgium image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of sigma19

ASKER

Thanks for your valuble comments.