AJAX: Datatable sorting using a4j:commandLink

Hi,
I have been using h:commandLink to sort data-table and display UP or DOWN arrow in JSF. But, when i moved to ajax-based, a4j:commandLink to sort by data-table, sort is not happening at all.
I am attaching code for a single <h:column>
<h:column id="c1">
<f:facet name="header">
<a4j:commandLink id="i21"
action="#{bean.sortByDate}"
reRender="suspList1">
<h:outputText id="i22" value="#{msg.date}" />
<%
if(objbean != null && objbean.isSortColumn(Constants.SORT_BY_DATE)) {
if(objbean != null && objbean.isListAscending()) {
%>
<f:verbatim>
<img id="image1" border="0" src="img/arrowup.gif">
</img>
</f:verbatim>
<%
} else {
%>
<f:verbatim>
<img id="image2" border="0" src="img/arrowdown.gif">
</img>
</f:verbatim>
<%
%>
</a4j:commandLink>
</f:facet>
<h:outputText id="i23" value="#{Item.runDate}" styleClass="left">
<f:convertDateTime pattern="MM/dd/yyyy" />
</h:outputText>
</h:column>
can you please help?
Thanks

SureshScreen wrote:
IMMTLY ASAP.After reading this my motivation to give an helpful answer went from 60% to 0%.
[Please ask questions the smart way|http://www.catb.org/~esr/faqs/smart-questions.html].

Similar Messages

  • Urgent -Help needed : a4j:CommandLink  'reRender ' not working.

    Hi,
    I am using <a4j:commandLink for my application to get the ajax functinality.
    Here i am rerendering a data table with the id -commentsId
    here is the Synatax, we dont have any clue to how do we progress on this.
    <a4j:commandLink value="submit1" reRender="commentsId" >
    <a4j:ajaxListener type="org.ajax4jsf.ajax.ForceRender" />
    </a4j:commandLink>
    Please help me.
    Thanks in advance.
    -Arthi.

    I had this problem 1 year ago, when check the keyboard cable see that all was correct...then
    Buy a new one, and now the keyboard works; maybe anybody throw water in the keyboard; please check first with a usb keyboard.

  • Using a4j to load a rich:dataTable after the page loads

    I have a rich:dataTable that calls a session bean which executes an SQL query to generate the data to be displayed in the table. Something simple like:
    <rich:dataTable rowClasses="evenRow,oddRow"
    rows="30"
    value="#{Bean.items}"
    var="items">
    where Bean.getItems() performs an SQL query and returns List<Item>.
    The problem is that the query takes a long time to execute (~45 seconds) and I'd like the page to initially load while the query is being executed, displaying a spinner while it loads. Once the query is done, I'd like to update the initially empty table using ajax.
    I set up a spinner using a4j:status and it works fine after the page initially loads (using a rich:datascroller).
    However, the page will not initially load until the query completes, which is a problem because the query is so slow. What happens is the user clicks on the "List Items" tab from my site's homepage, sits there on the same page for 45 seconds with absolutely no visual indication that anything is happening, and then finally is taken to the list of items page.
    What is needed to make the dataTable load via AJAX the first time, as well as all subsequent times?
    Thanks!
    Edited by: rcrowell on Sep 8, 2008 5:42 PM

    rcrowell wrote:
    The issue isn't the PK of the table; the query is joining across many tables and aggregating data from one table in particular with millions of rows. The table has paging, but again that won't help the timinig issues due to the aggregation that must be performed on a large table.
    Surely there must be a way to get the dataTable to always load its data via ajax, and not only after the first time.Well JSF does not have AJAX built-in, so why would there be? Perhaps one of the AJAX-based frameworks has this. I imagine it wouldn't be hard to do with the existing AJAX frameworks even without a built-in component specifically for it. Trigger an AJAX action on load which rerenders a panel which will only contain the dataTable upon the rerendering.
    >
    I think I could do it by adding a 'dataTableRendered' variable to the bean and using a jsFunction to set this variable to True when the page loads, but I'm looking for a better way. (I'm also not 100% sure this would do what I want.)

  • EL expression in JSF with a4j:commandLink

    hallo:
    I have a very strange problem with a el-expression. i need your help, thanks.
    i develop a project with JSF-RI,
    <rich:datascroller align="left" for="ein_post" page="#{alMessageHandler.scrollerPage}"
                        renderIfSinglePage="false" reRender="sc2" id="sc1" />
    <rich:dataTable width="985" headerClass="form_background peTable"
                             sortMode="single" id="ein_post" rows="#{alMessageHandler.pageSize}"
                             value="#{alMessageHandler.pagedListDataModel}" var="recivedMsg"
                             rowKeyVar="index">
    <rich:column width="75px" id="outbox6">
        <a4j:commandLink action="#{alMessageHandler.writeReplyMsg}"
         actionListener="#{alMessageHandler.catchMessageIdForReplay}"
         rendered="#{alMessageHandler.senders[index-(alMessageHandler.scrollerPage-1)*alMessageHandler.pageSize].activated}">
           reply
         <f:param value="#{receivedMsg.message.id}" id="receivedMessageIdForReplay"  name="receivedMessageIdForReplay"/>                              
        </a4j:commandLink>
    </rich:column>
    </rich:dataTable>i use a PagedListDataModel, which extends DataModel. in each message i have a link 'reply'.
    On the first page(the first page of rich:datascroller) i click reply link, then call the methode "catchMessageIdForReplay" then "writeReplyMsg", well done.
    but after i click the seconde page then cklick "reply" link. it would not work. it can not call method "catchMessageIdForReplay" then "writeReplyMsg".
    it returned to the first page. that is to say, it is only useful on the first page.
    watching: if i write the code like this "rendered="true". then no problem
    that's mean el-expression "rendered="#{alMessageHandler.senders[index-(alMessageHandler.scrollerPage-1)*alMessageHandler.pageSize].activated}"" on the seconde page can not working.
    Strange: i can dispaly the value of #{alMessageHandler.senders[index-(alMessageHandler.scrollerPage-1)*alMessageHandler.pageSize].activated}", the value is 'true'. but 'render' did not know the el-expression on the seconde page
    anybody can tell me why, and how to solve the problem ? thanks.
    Edited by: zlzc2000 on Oct 27, 2009 4:09 AM

    I am not very sure about your problem, but it might be releated to the bean state if your bean is in request scope. Trying using a4j:keepAlive in your jsp and see if it works. These type of problems happen sometimes with rendered and disbled attributes.
    regards,
    nirvan.

  • Passing object as parameter in JSF using h:commandLink tag

    Hi ,
    I have a scenario in which i need to pass objects from one jsp to another using h:commandLink. i read balusC article "Communication in JSF" and found a basic idea of achieving it. Thanks to BalusC for the wonderful article. But i am not fully clear on the concepts and the code is giving some error. The code i have is
    My JSP:
    This commandlink is inside a <h:column> tag of <h:dataTable>
    <h:commandLink id="ol3"action="ManageAccount" actionListener="#{admincontroller.action}" >
                   <f:param id="ag" name="account" value="#{admincontroller.account}" />
                   <h:outputText id="ot3" value="Manage Account" rendered="#{adminbean.productList!=null}" />
                   </h:commandLink>
    Also a binding in h:dataTable tag with the  binding="#{admincontroller.dataTable}"
                      My Backing Bean:
    public class CompanyAdminController {
              private HtmlDataTable dataTable;
              private Account account=new Account();
    public HtmlDataTable getDataTable() {
            return dataTable;
    public Account getAccount() {
             return this.account;
    public void setAccount(Account account) {
              this.account = account;
          public void action(){
                account= (Account)this.getDataTable().getRowData();
           } faces-config.xml
    <navigation-rule>
        <from-view-id>/compadmin.jsp</from-view-id>
        <navigation-case>
          <from-outcome>ManageAccount</from-outcome>
          <to-view-id>/manageAccount.jsp</to-view-id>
        </navigation-case>
      </navigation-rule>
    <managed-bean>
              <managed-bean-name>admincontroller</managed-bean-name>
              <managed-bean-class>com.forrester.AdminController</managed-bean-class>
              <managed-bean-scope>request</managed-bean-scope>
              <managed-property>
                   <property-name>account</property-name>
                   <property-class>com.model.Account</property-class>
                   <value>#{param.account}</value>
             </managed-property>
         </managed-bean>My account object:
    public class Account {
    string name;
      public String getName()
        return this.name;
      public void setName(String name)
           this.name=name;
      }I need to display #{admincontroller.account.name} in my forwarded jsp. But I am not sure whether the code i wrote in commandlink is correct. I get an error if i use <f:setActionListener> . No tag "setPropertyActionListener" defined in tag library imported with prefix "f"
    Please advise.
    Edited by: twisai on Oct 18, 2009 11:46 AM
    Edited by: twisai on Oct 18, 2009 11:47 AM
    Edited by: twisai on Oct 18, 2009 11:48 AM

    Yes.. iam removed the managedproperty from faces-config. But still i get the null pointer exception on main jsp itself and i am taken to second jsp manageaccount.jsp. Did you find anything wrong in my navigation case in the action method??
                                     public String loadAccount(){
               Account account = (Account)this.getDataTable().getRowData();
                return "ManageAcct";And also can you please answer this question i have
    The AdminController is the backing bean of 1st JSP and manageAccontController is the backing bean of forwarded JSP .
    Can i put this action method and dataTable binding in a 2nd manageAccontController backing bean instead of AdminController. But if i do that way dataList binding in h:dataTable tag will be in first JSP backing bean and dataTable binding to 2nd JSP. Not sure how to deal with this.
    {                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Form onsubmit ignored when using h:commandLink

    Hi
    I was looking for a way to catch all form submission in javascript by automatically setting a method to each form.onsubmit. But I ran into trouble with h:commandLink.
    I tested using a simple example:
    <h:form onsubmit="alert(123);">
    <h:commandButton value="commandButton"/>
    <h:commandLink value="commandLink"/>
    </h:form>Using this code, clicking the commandButton will display and alert with 123. But when clicking the commandLink, the onsubmit is ignored. The commandLink submit the form by javascript code using the form.submit() method. I tested it out (with firefox) and it seem to be the normal behavior... the onsubmit event is not triggered, unliked at normal <input type="submit"/> (like the commandButton).
    Looking at the javascript used the commandLink, I could see that it is completely ignoring the possibility that the user specified a onsubmit:
    //com/sun/faces/sunjsf.js
    function jsfcljs(f, pvp, t) {   
        apf(f, pvp);
        var ft = f.target;
        if (t) {
            f.target = t;
        f.submit();  
        f.target = ft;
        dpf(f);   
    };Wouldn't it make more sense to verify if a onsubmit method was set on the form and execute it before submitting the form?
    function jsfcljs(f, pvp, t) {   
        apf(f, pvp);
        var ft = f.target;
        if (t) {
            f.target = t;
         if (typeof(f.onsubmit) == "function") {
              var os = f.onsubmit();
              if (os != undefined && os == false) {
                   return false
        f.submit();  
        f.target = ft;
        dpf(f);   
    };The behavior of the commandLink would then match the JSF-API description:
    Tag commandLink : "Render an HTML "a" anchor element that acts like a form submit button when clicked."

    Wow! That worked when I removed the include directive. The only problem is that the include directive for the page is needed. When I use <c:import> or <jsp:include> it doesn't really include it correctly.
    Is there some special way I'm supposed to import JSF pages?
    Thanks again!

  • Dynamically validating datatable elements using javascript

    Hai, iam using jsf, and having Xml mapping to the form elements to display the data . Iam using <h:datatable> inside which iam haveing repeated elements, i need to do a javascript validation before displaying the form element present inside the <h:datatable> columns.Iam also using <j4j:idproxy> , the java script is working for 1 iteration but it is the dataof the form element is not getting overridden in the 2nd iteration, It is somethinglike this below.
    <TR id="buiCoverRowId" style="display:none;">
    <TD height="9" width="200"></f:verbatim> <h:outputText
    styleClass="outputText" id="text7"
    value="Buildings Cover"></h:outputText><f:verbatim></TD>
    <TD height="9" width="516"></f:verbatim> <h:outputText
    styleClass="outputText" id="buildCoverId"
    value="#{pathPart.xpathMap['./BuildingsCover/CoverDetail/SumInsured/Amount']}">
    </h:outputText> <f:verbatim></TD>
    </TR>
    <TR>
    <TD></f:verbatim><f:verbatim>
    <h:inputHidden id="hidBuiCoverId"
    value="#{pathPart.xpathMap['./BuildingsCover/CoverDetail/SumInsured/Amount']}">
    <j4j:idProxy id="hidBuiCoverId_" />
    </h:inputHidden>
    </f:verbatim><f:verbatim></TD>
    <TD></f:verbatim><f:verbatim>
    <h:inputHidden id="hidExBuiCoverId"
    value="#{pathPart.xpathMap['./BuildingsCover/ExcludedInd/Value']}">
    <j4j:idProxy id="hidExBuiCoverId_" />
    </h:inputHidden>
    </f:verbatim><f:verbatim></TD>
    </TR>
    <SCRIPT>
    alert("HAI");
    var buidcover = document.getElementById('hidExBuiCoverId_').title;
    var buidcoverR =document.getElementById(buidcover).value;
    alert("the value of buildcover----->"+buidcoverR);
    var buId =document.getElementById('hidBuiCoverId_').title;
    var entitybuId1 = document.getElementById(buId).value;
    entitybuIdT1 = trim(entitybuId1);
    alert("entitybuIdT1"+entitybuIdT1);
    var buExId = document.getElementById('hidExBuiCoverId_').title;
    var entitybuExId1 = document.getElementById(buExId).value;
    entitybuExIdT1 = trim(entitybuExId1);
    entitybuExIdU1 = entitybuExIdT1.toUpperCase();
    alert("entitybuExIdU1"+entitybuExIdU1);
    if(!(entitybuIdT1 == null || entitybuIdT1 == '') && ((entitybuIdT1 == "0")) && (entitybuExIdU1 == 'FALSE'))
    document.getElementById("buiCoverRowId").style.display="block";
    </SCRIPT>
    The form element is mapped to the xml. the above code is written within a datatable, iam using javascrpt within this to display the datat or not, it is working for first iteration but its not working for second iteration. Plz help me with this . Is there any way that i can use javascript so that it vvalidates the form elements even for the 2 iteration of the datattable. I am having thesame values (of the 1iteration) even during the 2 iteration. Plz help me with this asap.

    Got the solution.
    $("div.ms-acal-rootdiv div div div a").html().replace('Replace this text only.','Replaced Text');

  • Radix sort using integers

    Cany anyone help me convert my code to sort using integers and maybe using a Queue?
    Thanks in advance, I appreciate it.
    import java.util.*;
    public class RadixSort{
      String[] input;
      int maxLength;
      public RadixSort(String[] sa){
        input = sa;
        maxLength = input[0].length();
        for (int i = 1; i < input.length; ++i){
          if (input.length() > maxLength){
    maxLength = input[i].length();
    public String[] sort(){
    for (int i = maxLength -1; i > -1; --i){ //begin compare from the last char
    Arrays.sort(input, new RadixComparator(i));
    return input;
    // give two or more strings as command line args
    // ex. java RadixSort vouch wacky lover love banana ananas
    public static void main(String[] args){
    RadixSort rs = new RadixSort(args);
    String[] result = rs.sort();
    for (int i = 0; i < result.length; ++i){
    System.out.println(result[i]);
    class RadixComparator implements Comparator{
    int columnNum; //start from 0
    public RadixComparator(int col){
    columnNum = col;
    public int compare(Object o1, Object o2){
    char c1, c2;
    String s1 = (String)o1;
    String s2 = (String)o2;
    int l1 = s1.length();
    int l2 = s2.length();
    if (l1 < (columnNum + 1)){ //s1 too short
    if (l2 < (columnNum + 1)){ //both too short
    return 0;
    else{
    return -1;
    else if (l2 < (columnNum + 1)){ //s2 too short
    return 1;
    else{
    c1 = s1.charAt(columnNum);
    c2 = s2.charAt(columnNum);
    return (c1 - c2);

    sort using integersIf your integer set only contains positive numbers, you could readily use radix sort for strings for
    them. You could easily convert int[] to String[] and vice versa. If your integer set is a mix of
    positives and negatives, then you would have to run radix sort twice and concatenate the
    results. One for positives, and anothe for negatives -- the latter should be a reverse
    radix sort because -1234 is larger than -5678.

  • How to fix "Must be literal" error when using a4j:keepAlive tag?

    Hi everybody,
    When I use <a4j:keepAlive> tag of Richfaces like this:
    <a4j:keepAlive beanName="#{templateController.currentType}"/>I got the an error like this:
    /templates.xhtml @20,91 <a4j:keepAlive beanName="#{templateController.currentType}"> Must be literalIn my class, I have declared as:
    class TemplateController{
        private TemplateType currentType;
        public void setCurrentType(TemplateType type) {
        public TemplateType getCurrentType() {
    }I implemented as guide from Richfaces document but don't know why this happened.
    Could anyone tell me why? Please help me to fix it.
    I really appreciate it,
    Ringo
    Edited by: Ringo.CS on Jun 19, 2008 3:42 AM
    Edited by: Ringo.CS on Jun 19, 2008 3:43 AM

    No, the error message says that the value must be a literal and thus not an EL. I don't know anything about Ajax4jsf (you're in the wrong place to ask questions about it, rather use the forums of the Ajax4jsf manfacturer at jboss.com), but the attributename and errormessage together makes it logical to put just the raw managed bean name in there. If this is not what you're after, then just consult their documentation and forums at jboss.com.

  • IceFaces 1.8 dataTable-sort example gives error

    Hi All:
    I need help, please!! Any help or hint is greatly appreciated it!!
    In the tutorial from IceFaces 1.8
    Data Table Component Tutorials
    I am using weblogic 10.3.2, IceFaces 1.8 and Jsf 1.2.
    I am using the jars that comes with the IceFaces 1.8 download.
    index.jsp:
    <html>
    <head>
    <title>ICEfaces Component Showcase</title>
    </head>
    <body>
    <jsp:forward page="sortableTable.iface" />
    </body>
    </html>
    sortableTable.jspx:
    <f:view xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:ice="http://www.icesoft.com/icefaces/component">
    <ice:outputDeclaration doctypeRoot="HTML"
    doctypePublic="-//W3C//DTD HTML 4.01 Transitional//EN"
    doctypeSystem="http://www.w3.org/TR/html4/loose.dtd"/>
    <html>
    <head>
    <meta http-equiv="Content-Type"
    content="text/html; charset=iso-8859-1"></meta>
    <title>DataTable Component Tutorial</title>
    <link href="./xmlhttp/css/xp/xp.css" rel="stylesheet" type="text/css"/>
    </head>
    <body>
    <h2>Sortable dataTable Component</h2>
    <p>In this example commandSortHeader components have been added to the
    table headers. Clicking on the headers will sort the table data.</p>
    <ice:form>
    <!--
    This is a very basic table comprising four columns. Each
    row represents an inventory item. Each column represents a
    inventory item property. commandSortHeader components have been
    added ot the table headers.
    The sortAscending and sortColumn attributes are set when a command
    sortColumnName header is activated. The sortColumn and sortAscending
    data can then be sortColumnName by a sortColumnName algorithm if a
    change is detected.
    -->
    <ice:dataTable
    id="dataSortData"
    sortColumn="#{inventoryList.sortColumnName}"
    sortAscending="#{inventoryList.ascending}"
    value="#{inventoryList.carInventory}"
    var="item">
    <!-- Stock number -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.stockColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.stockColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.stock}"/>
    </ice:column>
    <!-- Model number -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.modelColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.modelColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.model}"/>
    </ice:column>
    <!-- Description -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.descriptionColumnName} "
    arrow="true" >
    <ice:outputText value="#{inventoryList.descriptionColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.description}"/>
    </ice:column>
    <!-- Odometer reading -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.odometerColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.odometerColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.odometer}"/>
    </ice:column>
    <!-- Price number -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.priceColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.priceColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.price}"/>
    </ice:column>
    </ice:dataTable>
    </ice:form>
    </body>
    </html>
    </f:view>
    Error 500--Internal Server Error
    java.lang.Exception: javax.faces.FacesException: Can't parse stream for /index.jsp The prefix "jsp" for element "jsp:forward" is not bound.
    at com.icesoft.faces.context.View.servePage(View.java :152)
    at com.icesoft.faces.webapp.http.core.MultiViewServer .service(MultiViewServer.java:67)
    at com.icesoft.faces.webapp.http.common.ServerProxy.s ervice(ServerProxy.java:11)
    at com.icesoft.faces.webapp.http.servlet.MainSessionB oundServlet$4.service(MainSessionBoundServlet.java :149)
    at com.icesoft.faces.webapp.http.common.standard.Path DispatcherServer.service(PathDispatcherServer.java :24)
    at com.icesoft.faces.webapp.http.servlet.BasicAdaptin gServlet.service(BasicAdaptingServlet.java:16)
    at com.icesoft.faces.webapp.http.servlet.PathDispatch er.service(PathDispatcher.java:23)
    at com.icesoft.faces.webapp.http.servlet.SessionDispa tcher.service(SessionDispatcher.java:53)
    at com.icesoft.faces.webapp.http.servlet.PathDispatch er.service(PathDispatcher.java:23)
    at com.icesoft.faces.webapp.http.servlet.MainServlet. service(MainServlet.java:131)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:820)
    at weblogic.servlet.internal.StubSecurityHelper$Servl etServiceAction.run(StubSecurityHelper.java:227)
    at weblogic.servlet.internal.StubSecurityHelper.invok eServlet(StubSecurityHelper.java:125)
    at weblogic.servlet.internal.ServletStubImpl.execute( ServletStubImpl.java:292)
    at weblogic.servlet.internal.TailFilter.doFilter(Tail Filter.java:26)
    at weblogic.servlet.internal.FilterChainImpl.doFilter (FilterChainImpl.java:56)
    at weblogic.servlet.internal.RequestEventsFilter.doFi lter(RequestEventsFilter.java:27)
    at weblogic.servlet.internal.FilterChainImpl.doFilter (FilterChainImpl.java:56)
    at weblogic.servlet.internal.WebAppServletContext$Ser vletInvocationAction.run(WebAppServletContext.java :3592)
    at weblogic.security.acl.internal.AuthenticatedSubjec t.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(Se curityManager.java:121)
    at weblogic.servlet.internal.WebAppServletContext.sec uredExecute(WebAppServletContext.java:2202)
    at weblogic.servlet.internal.WebAppServletContext.exe cute(WebAppServletContext.java:2108)
    at weblogic.servlet.internal.ServletRequestImpl.run(S ervletRequestImpl.java:1432)
    at weblogic.work.ExecuteThread.execute(ExecuteThread. java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java :173)
    Caused by: javax.faces.FacesException: Can't parse stream for /index.jsp The prefix "jsp" for element "jsp:forward" is not bound.
    at com.icesoft.faces.application.D2DViewHandler.rende rResponse(D2DViewHandler.java:445)
    at com.icesoft.faces.application.D2DViewHandler.rende rView(D2DViewHandler.java:159)
    at com.sun.faces.lifecycle.RenderResponsePhase.execut e(RenderResponsePhase.java:110)
    at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:1 00)
    at com.sun.faces.lifecycle.LifecycleImpl.render(Lifec ycleImpl.java:139)
    at com.icesoft.faces.webapp.http.core.JsfLifecycleExe cutor.apply(JsfLifecycleExecutor.java:19)
    at com.icesoft.faces.context.View$2$1.respond(View.ja va:48)
    at com.icesoft.faces.webapp.http.servlet.ServletReque stResponse.respondWith(ServletRequestResponse.java :201)
    at com.icesoft.faces.context.View$2.serve(View.java:7 7)
    at com.icesoft.faces.context.View.servePage(View.java :149)
    ... 25 more
    Caused by: org.xml.sax.SAXParseException: The prefix "jsp" for element "jsp:forward" is not bound.
    at com.sun.org.apache.xerces.internal.parsers.Abstrac tSAXParser.parse(AbstractSAXParser.java:1231)
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserI mpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
    at weblogic.xml.jaxp.WebLogicXMLReader.parse(WebLogic XMLReader.java:133)
    at weblogic.xml.jaxp.RegistryXMLReader.parse(Registry XMLReader.java:173)
    at org.apache.commons.digester.Digester.parse(Digeste r.java:1785)
    at com.icesoft.faces.webapp.parser.Parser.parse(Parse r.java:130)
    at com.icesoft.faces.application.D2DViewHandler.rende rResponse(D2DViewHandler.java:439)
    ... 34 more

    Hi All:
    I need help, please!! Any help or hint is greatly appreciated it!!
    In the tutorial from IceFaces 1.8
    Data Table Component Tutorials
    I am using weblogic 10.3.2, IceFaces 1.8 and Jsf 1.2.
    I am using the jars that comes with the IceFaces 1.8 download.
    index.jsp:
    <html>
    <head>
    <title>ICEfaces Component Showcase</title>
    </head>
    <body>
    <jsp:forward page="sortableTable.iface" />
    </body>
    </html>
    sortableTable.jspx:
    <f:view xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:ice="http://www.icesoft.com/icefaces/component">
    <ice:outputDeclaration doctypeRoot="HTML"
    doctypePublic="-//W3C//DTD HTML 4.01 Transitional//EN"
    doctypeSystem="http://www.w3.org/TR/html4/loose.dtd"/>
    <html>
    <head>
    <meta http-equiv="Content-Type"
    content="text/html; charset=iso-8859-1"></meta>
    <title>DataTable Component Tutorial</title>
    <link href="./xmlhttp/css/xp/xp.css" rel="stylesheet" type="text/css"/>
    </head>
    <body>
    <h2>Sortable dataTable Component</h2>
    <p>In this example commandSortHeader components have been added to the
    table headers. Clicking on the headers will sort the table data.</p>
    <ice:form>
    <!--
    This is a very basic table comprising four columns. Each
    row represents an inventory item. Each column represents a
    inventory item property. commandSortHeader components have been
    added ot the table headers.
    The sortAscending and sortColumn attributes are set when a command
    sortColumnName header is activated. The sortColumn and sortAscending
    data can then be sortColumnName by a sortColumnName algorithm if a
    change is detected.
    -->
    <ice:dataTable
    id="dataSortData"
    sortColumn="#{inventoryList.sortColumnName}"
    sortAscending="#{inventoryList.ascending}"
    value="#{inventoryList.carInventory}"
    var="item">
    <!-- Stock number -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.stockColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.stockColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.stock}"/>
    </ice:column>
    <!-- Model number -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.modelColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.modelColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.model}"/>
    </ice:column>
    <!-- Description -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.descriptionColumnName} "
    arrow="true" >
    <ice:outputText value="#{inventoryList.descriptionColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.description}"/>
    </ice:column>
    <!-- Odometer reading -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.odometerColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.odometerColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.odometer}"/>
    </ice:column>
    <!-- Price number -->
    <ice:column>
    <f:facet name="header">
    <ice:commandSortHeader
    columnName="#{inventoryList.priceColumnName}"
    arrow="true" >
    <ice:outputText value="#{inventoryList.priceColumnName}"/>
    </ice:commandSortHeader>
    </f:facet>
    <ice:outputText value="#{item.price}"/>
    </ice:column>
    </ice:dataTable>
    </ice:form>
    </body>
    </html>
    </f:view>
    Error 500--Internal Server Error
    java.lang.Exception: javax.faces.FacesException: Can't parse stream for /index.jsp The prefix "jsp" for element "jsp:forward" is not bound.
    at com.icesoft.faces.context.View.servePage(View.java :152)
    at com.icesoft.faces.webapp.http.core.MultiViewServer .service(MultiViewServer.java:67)
    at com.icesoft.faces.webapp.http.common.ServerProxy.s ervice(ServerProxy.java:11)
    at com.icesoft.faces.webapp.http.servlet.MainSessionB oundServlet$4.service(MainSessionBoundServlet.java :149)
    at com.icesoft.faces.webapp.http.common.standard.Path DispatcherServer.service(PathDispatcherServer.java :24)
    at com.icesoft.faces.webapp.http.servlet.BasicAdaptin gServlet.service(BasicAdaptingServlet.java:16)
    at com.icesoft.faces.webapp.http.servlet.PathDispatch er.service(PathDispatcher.java:23)
    at com.icesoft.faces.webapp.http.servlet.SessionDispa tcher.service(SessionDispatcher.java:53)
    at com.icesoft.faces.webapp.http.servlet.PathDispatch er.service(PathDispatcher.java:23)
    at com.icesoft.faces.webapp.http.servlet.MainServlet. service(MainServlet.java:131)
    at javax.servlet.http.HttpServlet.service(HttpServlet .java:820)
    at weblogic.servlet.internal.StubSecurityHelper$Servl etServiceAction.run(StubSecurityHelper.java:227)
    at weblogic.servlet.internal.StubSecurityHelper.invok eServlet(StubSecurityHelper.java:125)
    at weblogic.servlet.internal.ServletStubImpl.execute( ServletStubImpl.java:292)
    at weblogic.servlet.internal.TailFilter.doFilter(Tail Filter.java:26)
    at weblogic.servlet.internal.FilterChainImpl.doFilter (FilterChainImpl.java:56)
    at weblogic.servlet.internal.RequestEventsFilter.doFi lter(RequestEventsFilter.java:27)
    at weblogic.servlet.internal.FilterChainImpl.doFilter (FilterChainImpl.java:56)
    at weblogic.servlet.internal.WebAppServletContext$Ser vletInvocationAction.run(WebAppServletContext.java :3592)
    at weblogic.security.acl.internal.AuthenticatedSubjec t.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(Se curityManager.java:121)
    at weblogic.servlet.internal.WebAppServletContext.sec uredExecute(WebAppServletContext.java:2202)
    at weblogic.servlet.internal.WebAppServletContext.exe cute(WebAppServletContext.java:2108)
    at weblogic.servlet.internal.ServletRequestImpl.run(S ervletRequestImpl.java:1432)
    at weblogic.work.ExecuteThread.execute(ExecuteThread. java:201)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java :173)
    Caused by: javax.faces.FacesException: Can't parse stream for /index.jsp The prefix "jsp" for element "jsp:forward" is not bound.
    at com.icesoft.faces.application.D2DViewHandler.rende rResponse(D2DViewHandler.java:445)
    at com.icesoft.faces.application.D2DViewHandler.rende rView(D2DViewHandler.java:159)
    at com.sun.faces.lifecycle.RenderResponsePhase.execut e(RenderResponsePhase.java:110)
    at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:1 00)
    at com.sun.faces.lifecycle.LifecycleImpl.render(Lifec ycleImpl.java:139)
    at com.icesoft.faces.webapp.http.core.JsfLifecycleExe cutor.apply(JsfLifecycleExecutor.java:19)
    at com.icesoft.faces.context.View$2$1.respond(View.ja va:48)
    at com.icesoft.faces.webapp.http.servlet.ServletReque stResponse.respondWith(ServletRequestResponse.java :201)
    at com.icesoft.faces.context.View$2.serve(View.java:7 7)
    at com.icesoft.faces.context.View.servePage(View.java :149)
    ... 25 more
    Caused by: org.xml.sax.SAXParseException: The prefix "jsp" for element "jsp:forward" is not bound.
    at com.sun.org.apache.xerces.internal.parsers.Abstrac tSAXParser.parse(AbstractSAXParser.java:1231)
    at com.sun.org.apache.xerces.internal.jaxp.SAXParserI mpl$JAXPSAXParser.parse(SAXParserImpl.java:522)
    at weblogic.xml.jaxp.WebLogicXMLReader.parse(WebLogic XMLReader.java:133)
    at weblogic.xml.jaxp.RegistryXMLReader.parse(Registry XMLReader.java:173)
    at org.apache.commons.digester.Digester.parse(Digeste r.java:1785)
    at com.icesoft.faces.webapp.parser.Parser.parse(Parse r.java:130)
    at com.icesoft.faces.application.D2DViewHandler.rende rResponse(D2DViewHandler.java:439)
    ... 34 more

  • Jsf dataTable sort

    Hi all,
    How can the contents of dataTable component be sorted, tomahawk dataTable component provides a commandSortHeader how to use this, can any one show an example on how to write the sort handler ?
    Thanks in advance

    I think that the examples should have the source. Unfortunatly don't. I've decompiled the code, and i post here what you need:
    package org.apache.myfaces.examples.listexample;
    public abstract class SortableList
    protected SortableList(String defaultSortColumn)
    _sort = defaultSortColumn;
    _ascending = isDefaultAscending(defaultSortColumn);
    protected abstract void sort(String s, boolean flag);
    protected abstract boolean isDefaultAscending(String s);
    public void sort(String sortColumn)
    if(sortColumn == null)
    throw new IllegalArgumentException("Argument sortColumn must not be null.");
    if(_sort.equals(sortColumn))
    ascending = !ascending;
    } else
    _sort = sortColumn;
    ascending = isDefaultAscending(sort);
    sort(_sort, _ascending);
    public String getSort()
    return _sort;
    public void setSort(String sort)
    _sort = sort;
    public boolean isAscending()
    return _ascending;
    public void setAscending(boolean ascending)
    _ascending = ascending;
    private String _sort;
    private boolean _ascending;
    package org.apache.myfaces.examples.listexample;
    import java.util.*;
    // Referenced classes of package org.apache.myfaces.examples.listexample:
    // SortableList, SimpleCar
    public class SimpleSortableCarList extends SortableList
    public SimpleSortableCarList()
    super("type");
    _cars = new ArrayList();
    _cars.add(new SimpleCar(1, "car A", "red"));
    _cars.add(new SimpleCar(1, "car B", "blue"));
    _cars.add(new SimpleCar(1, "car C", "green"));
    _cars.add(new SimpleCar(1, "car D", "yellow"));
    _cars.add(new SimpleCar(1, "car E", "orange"));
    public List getCars()
    sort(getSort(), isAscending());
    return _cars;
    protected boolean isDefaultAscending(String sortColumn)
    return true;
    protected void sort(final String column, final boolean ascending)
    Comparator comparator = new Comparator() {
    public int compare(Object o1, Object o2)
    SimpleCar c1 = (SimpleCar)o1;
    SimpleCar c2 = (SimpleCar)o2;
    if(column == null)
    return 0;
    if(column.equals("type"))
    return ascending ? c1.getType().compareTo(c2.getType()) : c2.getType().compareTo(c1.getType());
    if(column.equals("color"))
    return ascending ? c1.getColor().compareTo(c2.getColor()) : c2.getColor().compareTo(c1.getColor());
    else
    return 0;
    Collections.sort(_cars, comparator);
    private List _cars;
    The code was decompiled with:
    // Decompiled by Jad v1.5.8f. Copyright 2001 Pavel Kouznetsov.
    // Jad home page: http://www.kpdus.com/jad.html

  • (Tomahawk) DataTable sort question

    Hello,
    I'm showing the system properties on a webpage. The backing bean simply returns a list of entries (java.util.Map.Entry) which are shown by a t:datatable (backing bean has request scope).
    So now that they are there, I'd like to have them sorted one way or another. I don't know how to use the sortColumn attribute in this case, perhaps I'll need to sort them in the backing bean instead?
    Thanks,
    Dave

    Hi!
    you dont need to stor in the been.
    you can do it in the jsp page like this: (using DataTable from RichFaces)
    <rich:extendedDataTable  sortPriority="#{spot.startTimeForTable}"
                   value="#{scheduleResultBean.lspotsOnDate}" var="spot" id="spots"
                   rowClasses="#{spot.statusName}" >
                   <rich:column sortBy="#{spot.rating}" filterBy="#{spot.rating}"
                        filterEvent="onkeyup" label="Rating" >
                        <f:facet name="header">
                             <h:outputText value="Rating" />
                        </f:facet>
                        <h:outputText value="#{spot.rating}">
                        </h:outputText>
                   </rich:column>
    </rich:extendedDataTable>I'd like to hear if it helped you to!

  • X:dataTable sort arrow rendered as question mark (?)

    Hey All:
    I am using tomahawk 1.1.3 and when I use sortable columns with x:dataTable, the sort arrows are being rendered as question marks (?). Any ideas?

    were would be the place to find the original system install CD.
    Ideally, your friend:
    My Friend gave me his Old Imac G5
    The Apple Store may have original system install discs but I would be surprised since no Apple Store in the US that I know of sells them any longer.
    It will not be free, but if they have one that would be the best option. Otherwise you will have to peruse the used market. In the US that could be Amazon Marketplace or eBay. I do not know where you would start in India, but many eBay sellers ship worldwide.
    Make absolutely certain you are getting a full retail installation CD and if it is Leopard or Tiger, make sure it is for your G5 and not an Intel iMac. System specific disks are grey in color and will not work except for the exact system with which they were included.

  • DataTable sort

    I need to display a sortable dataTable. I look in some forums and find soemthings like this:
    <h:dataTable sortable=true sortColumn="#{list.sort}" ...>
    But in my environement, it is impossible to write "sortable" and "sortColumn" attributes:
    "Atribute sortable invalid for tag dataTable according to TLD"
    Environement:
    - IDE=NetBeans 6.7.1
    - Server=Glassfish v3 Prelude Domain
    Any idea ?

    .. and in Tomahawk datatable.
    If you insist in using the RI datatable, or rather want the most effective method to page and sort a table in JSF, then check this article: [http://balusc.blogspot.com/2008/10/effective-datatable-paging-and-sorting.html].

  • How do I open a page in new window using af:commandLink?

    Hi,
    I have a requirement where I need to open the page in a new window on clicking the af:commandLink.
    I could use af:goLink, but I cannot as I have to invoke the URL using http POST method. If I use af:goLink, all the parameters will be displayed in the URL. I do not want that.
    I have the below code for the commandLink:
    <af:commandLink text="Open new window" id="cl199bk"
    styleClass="AFRighColLinkText"
    action="dialog:openNewWindow"
    useWindow="true" windowHeight="400"
    windowWidth="800" immediate="true"/>
    When I click the commandLink, the page gets opened but in the same window. I have the below controlflow-case in my taskflow:
    <control-flow-case id="__71">
    <from-outcome id="__133">dialog:openNewWindow</from-outcome>
    <to-activity-id id="__72">openNewWindow</to-activity-id>
    </control-flow-case>
    Please let me know what to do to have the page opened in new window/tab.
    Thanks in advance!

    Hi Frank,
    I tried that too and the page always opened in the same page even with dialog:action set and useWindow set to true. I had the navigation rule in adfc-config as well.
    I got it done using the url-view activity.
    I have created a new bounded task flow with the url-view activity as the default activity. I called this new task flow from the actionListener bean method on commandLink. Set the new task flow to url-invoke-allowed.
    I have my parameters set in the url-view activity. With this the parameters are not shown in the URL.
    That did the trick for me.
    Thanks.

Maybe you are looking for

  • Will I need to install OS X Lion?

    Hello, Im currently running Snow Leopard and I wish to get the Moutian Lion OS when it comes out. So Im wondering that do I need to install Lion first or can I go straight ahead and install Moutiain Lion.

  • Radio buttons! Can someone please help?

    I'm developing in PHP/MySQL. I've created a form consisting of a userID text form field, a RadioButtonGroup (3 radio buttons) and a submit button. The idea is to populate the MySQL database with the data entered by the user. The problem I'm experienc

  • Use of Spatial in connection with ODP

    I can't find anything about this subject. Is it possible to retrieve and update spacial geometry data using ODP?

  • Help Viewer doesn't help...AFP connection status?

    I use Airport Extreme Basestation 'n' to connect to the internet. When I use the "Help"menu (Mac Help), I get a spinning beach ball and a box that says, AFP Connection Status...Looking up "XXXXXX'S Computer." I click on the "Cancel" button, nothing h

  • Adobe Premiere CS3- CS6

    I buy an update version of Adobe Premiere CS3->CS6. Can i install on a PC with Adobe Creative Suite CS3 ? Can i install this version on a PC without CS3 ? Thanks.