Problem using JSF + ajax4jsf:poll component

I have the following problem.
I have JSF page and ajax4jsf:poll component on it for polling the server.
There are also couple links and buttons on the page,
At first, when polling is not enabled the links and buttons work fine.
But after enabling polling and its' work, links and buttons stop working and the page is only reloaded when I click on them. Accoring to the logs action methods, binded to that links and buttons, are not invoked at all. And log shows that page is rerendered using ajax. But not pure JSF which we use in general case.
Does anybody have any ideas, why this can be? I looked through the internet and I could not find similar problems.
I will appreciate any ideas. Thanks.

I have never used it, but did you try the example as given at the related developer guide? Please note the a4j:region and the placement at its own form instead of in another/shared form.
[http://www.jboss.org/file-access/default/members/jbossrichfaces/freezone/docs/devguide/en/html/poll.html]

Similar Messages

  • Problem displaying error page of web.xml when using JSF, Ajax4jsf

    Hi,
    My application is using MyFaces, RichFaces and Ajax4jsf. When i try to display error page configured in web.xml, i am getting exception "Error while processing error page".
    my web.xml contents are as follows:
    <?xml version="1.0"?>
    <web-app version="2.4" 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">
    <filter>
    <display-name>RichFaces Filter</display-name>
    <filter-name>richfaces</filter-name>
    <filter-class>org.ajax4jsf.Filter</filter-class>
    </filter>
    <filter-mapping>
    <filter-name>richfaces</filter-name>
    <servlet-name>faces</servlet-name>
    <dispatcher>REQUEST</dispatcher>
    <dispatcher>FORWARD</dispatcher>
    <dispatcher>INCLUDE</dispatcher>
    </filter-mapping>
    <filter>
    <filter-name>extensionsFilter</filter-name>
    <filter-class>
    org.apache.myfaces.webapp.filter.ExtensionsFilter
    </filter-class>
    <init-param>
    <description>
    set the size limit for uploaded files. Format: 10 - 10 bytes 10k
    - 10 KB 10m - 10 MB 1g - 1 GB
    </description>
    <param-name>uploadMaxFileSize</param-name>
    <param-value>100m</param-value>
    </init-param>
    <init-param>
    <description>
    Set the threshold size - files below this limit are stored in
    memory, files above this limit are stored on disk.
    Format: 10 - 10 bytes 10k - 10 KB 10m - 10 MB 1g - 1 GB
    </description>
    <param-name>uploadThresholdSize</param-name>
    <param-value>100k</param-value>
    </init-param>
    </filter>
    <filter>
    <filter-name>Seam Redirect Filter</filter-name>
    <filter-class>org.jboss.seam.servlet.SeamRedirectFilter</filter-class>
    </filter>
    <filter>
    <filter-name>KTServletFilter</filter-name>
    <filter-class>com.kenexa.core.system.KTServletFilter</filter-class>
    </filter>
    <filter-mapping>
    <filter-name>extensionsFilter</filter-name>
    <url-pattern>*.jsf</url-pattern>
    </filter-mapping>
    <filter-mapping>
    <filter-name>extensionsFilter</filter-name>
    <url-pattern>/faces/*</url-pattern>
    </filter-mapping>
    <filter-mapping>
    <filter-name>Seam Redirect Filter</filter-name>
    <url-pattern>*.jsf</url-pattern>
    </filter-mapping>
    <filter-mapping>
    <filter-name>KTServletFilter</filter-name>
    <url-pattern>*.jsf</url-pattern>
    </filter-mapping>
    <!-- seam Listeners -->
    <listener>
    <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
    </listener>
    <listener>
    <listener-class>com.kenexa.kr.web.KRServletListener</listener-class>
    </listener>
    <servlet>
    <servlet-name>faces</servlet-name>
    <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
    <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
    <servlet-name>faces</servlet-name>
    <url-pattern>*.jsf</url-pattern>
    </servlet-mapping>
    <error-page>
    <exception-type>java.lang.Throwable</exception-type>
    <location>/rc/systemError.jsf</location>
    </error-page>
    </web-app>
    As per the configuration, when exception is thrown out of the application, container tries to display systemError.jsp page. If we want to include the JSF tags in systemError.jsp page, the request should pass through FacesServlet, so in the <error-page> <location> tag systemError page is specified with the extention systemError.jsf though it's actual extention is .jsp
    When exception is thrown from the application container invoke the error page but, while rendering systemError.jsf page exception is thrown saying "Exception processing error page "systemError.jsp" "
    To solve this problem i've gone through several forums, materials.
    In one forum a guy said, JSF1.1 spec has some problem in displaying error pages. To solve this don't write <f:view> tags in the error page, use <f:subview> intstead. By reading this, i again changed the contents of systemError.jsp page replacing <f:view> by <f:subview>. But the error is still repeating.
    Finally what i found is, when we use Ajax4jsf in the application, its AjaxViewRender class is throwing exception while rendering error pages configured through web.xml.
    So what i did is i changed error page extention from .jsf to .jsp in the <location> tag. Now jsf won't come in the picture and remove JSF related tags from the systemError.jsp page.
    <error-page>
    <exception-type>java.lang.Throwable</exception-type>
    <location>/rc/systemError.jsp</location>
    </error-page>
    Any comments are welcome----------------------------------------------------------------

    I too iam facing the same problem could you advise if you have found any solutions
              -Ram

  • Problem using jsf  connection db

    i have this problem:
    I have defined a connection as a variable in a jsfbean with scope session scope.
    Clicking very quicly on a field on the form I get the message: sql result set closed and my connection variable is null.
    It seems a thread problem ; only one browser is open and I click inside the only form that I have.
    How may I resolve the problem ?
    I use Myfaces 1.1.5 and Tomahawk 1.1.5

    i have this problem:
    I have defined a connection as a variable in a jsfbean with scope session scope.
    Clicking very quicly on a field on the form I get the message: sql result set closed and my connection variable is null.
    It seems a thread problem ; only one browser is open and I click inside the only form that I have.
    How may I resolve the problem ?
    I use Myfaces 1.1.5 and Tomahawk 1.1.5

  • Problem using javascript to submit jsf form, values not submitted

    Greetings!
    I have a t:selectOneMenu where I want the page to be submitted when they change the selected value. At this point, I am able to get the form to submit and reload the page, which is all fine. The problem is that none of the values from the page are not set in the backing bean. I have break points on the setter methods that are not being hit.
    I have tried a number of things from searching multiple forums, but here are snippets from my latest version...
    <h:form>
    <t:commandLink id="hiddenLink" forceId="true" value="test link"
    action="#{pc_PageX.doBtnHiddenLinkAction}"></t:commandLink>
    <t:selectOneMenu id="pageList_top" forceId="true" value="#{pc_PageX.ValueX}"
         onchange="jspellSync(); submitPageX();">
         <f:selectItems value="#{pc_PageX.ListX}" />
    </t:selectOneMenu>
    </h:form>
    function submitPageX(){
         var hiddenLink = document.getElementById("hiddenLink");
         hiddenLink.click();
    }Note that the <t:commandLink> is not hidden, though it will be in the final version if I can get this to work.
    If I click the commandLink myself, the page is submitted with all the page values as expected. If I change the list value, thus using javascript to fire the commandLink's click event, the page is submitted with NO values.
    Can anyone come up with an explanation for this behavior? Or better yet, a solution?
    A couple other things I've tried...
    - Not using a commandLink and using jsf's submit function -> onchange="jspellSync(); submit();"
    - Clicking the link using other ways -> hiddenLink.fireEvent('onclick');
    If all else fails, I'll just add a button that they have to click to submit the form.

    snotmare wrote:
    BalusC wrote:
    I recall this problem in one of the ancient JSF versions. Which JSF version do you use? Do you have any room to upgrade to latest? We're using an IBM implementation of JSF, which is at version 7.0. The IBM implementation appears to be built on the JSF base 1.1.That's not an IBM JSF implementation, they do not have any one, they just have some component libraries which runs on top of some JSF implementation. RAD/WSAD ships by default with Sun JSF RI. Try upgrading to at least 1.1_02 which you can download from the aforementioned link. There's a gap of 2 years (and inherently a lot of bugfixes) compared to 1.1. If the application server used supports Servlet 2.5, you could even upgrade to the latest 1.2.
    We've had other issues with the IBM implementation, which could be the cause in this case too. We've been talking about switching to MyFaces, but there is one feature of the IBM version that we like. It's basically a script collector (hx:scriptCollector) that allows us to do pre-processing on the page.As said before, IBM does not have a JSF implementation. So replacing RI by MyFaces wouldn't make any difference.

  • Problem in JSF addRemoveList component selection

    Hi,
    We are using JSF creator studio 2.0. In our project we are using addRemoveList component to display available and selected items.
    We are able to display the selected value from available list to Selected list.
    uisng Add and remove buttons of the AddremoveList component.
    But we are facing the problem is, we are unable to get particular selected or highlighted value from the SelectedList .
    However we are able to get all selected items in bakingBean.
    This is very very important for us to move further in our development. I really appreciate for any sort of help.
    Thanks,
    Ramesh

    Hey Andy,
    I did it that way (JSC 2):
    assuming the add remove component's id is arl and that the components' item-property is bound to a datatable (mysql). The value field is of type Long, the display field is of type String.
    Get selected:
    get an array of selected objects directly from the component, and then do what ever you like to with that array.
    Object[] objSel = (Object[]) arl.getSelected();
    int i;
    int l = objSel.length;
    String str;
    for (i = 0; i < l ; i++) {
    str = objSel.toString();
    Set selected:
    Just create an array of objects holding the selected values and pass it to the component. But, attention, you'll need to make sure you're feeding the object array with the correct types of values. In my sample the value is a Long as described above, so I also need to pass in a Long, else the component just does nothing at all.
    Object[] selObj = new Object[] {new Long(5), new Long(8)};
    arl.setSelected(selObj);
    I found this the most easy option to get and set the add remove list selection.
    An other quite easy option is to bind the selected-property of the component to any session-bean property of type object-array and then set this sessionbean-property to the approrpiate values. But here you need also to make sure the datatype is correct.

  • Problem with fixing pagerdeluxe and progressbar while using jsf-ibm.jar

    hi,
    I am having a jsf data table with <hx:pagerdeluxe> to navigate, and i am using (jsf-ibm-unknown-vers.jar) jar, this works fine. I need to insert a progress bar in my jsf and used <hx:progressBar> but this was not available in the old jar, So i upgraded my jar to jsf-ibm.jar when i ran this progress bar works fine but he pager deluxe shrinks and unable to navigate.. I am using jboss server .... Can any one help me out about regarding this. So that both works fine
    Thanks.
    Rakesh M

    This is not related to Sun JSF. You might have more luck if you ask component library specific questions at the website/forum/mailinglist of the component manfacturer.

  • Problems using "Edit Column Widths" feature in List View component

    Hello. I'm using a list view component (Xcelsius 4.5 Professional) to display a simple table of text from Excel. I want to adjust the width of the component colums so that all of them fit on the screen at the same time- regardless of how wide they are in the excel columns. The problem is the columns in excel are of variable length; I have no way to predict how wide they will be. The list view component always defaults to the widest column(s) so it ends up pushing some of the columns to the right and  I then have to use the scroll bar to see them. I thought the "edit column widths" would allow me to force the column widths in the component (potentially truncating some of the columns), but it does not work that way.
    How is the "edit column width" feature supposed to work? What does one enter in the value for each label? Are the units in pixels? When I start entering values I get all kinds of strange behavior...

    This was a great place for me to start
    Thank you
    I took profdant139's suggestions a bit further as my real goal was to have the "Document column" narrower. The goal to be able to see all the other document info that was usually hidden way out to the right
    To achieve my results I right clicked in the upper bar with the column names and chose from the drop down box "comments" column (as suggested). I then dragged it to the far right. This pushed all the other columns over.
    In the end of the day I ended up adding "Size" and "Date modified" columns as well to get my desired results.
    Remember one can move different columns around to be in the order you need by clicking on the column to get it active and then left click and drag it to where you want
    Another great thing is that by default (Using Mavericks) the date modified, opened,created columns have date and time. One can shrink them down to xx/xx/xx format by manually adjusting the column width like one does in Excel - click on column separator up top and drag
    Once all that is done, at least on my box, I closed it out and opened up a new finder window and everything was as I wanted.
    Thank you for the help  from the above helper to get me here

  • Query SQL database using JSF problem!! Using CachedRowSet

    I'm using JSF and want to query data from SQL by using CachedRowSet like this,
    rowset.setCommand("SELECT * FROM dbo.SomeTable WHERE SomeField='"+ xyz +"'");
    then check if the record does exist by using
    *if(rowset.next()) {/ do something with the retrieved data}*
    but i get SQLException telling that execute() never called.
    Anyone can tell me what i'm missing? or is there any better way to check the existence of a record ?
    Thanks in advance :-)

    Hi grzegorz,
    1. If your sap application server is unix/aix
      (and not a microsoft OS),
    2. then this kind of secondary databse connection,
       to MS SQL (which is microsoft system),
       is at present not possible.
      (BCOS the required system files, for such
       cross - platform connection is not delivery by sap)
    regards,
    amit m.

  • Problems using Apple Component AV cable

    I can not seem to use the Apple AV component cable to watch videos from my iPhone onto my Samsung TV.
    I have made all the right connections between the iPhone and TV, I believe. However, i was not able to watch any of my iPhone videos on my TV yet. The AV cable's Manual does mention to set "to send your ipod or iphone to send a video signal out to your TV" - which I do not know how to do on my iphone. I have not seen any "TV Out" setting on my iphone.
    Can anyone help? I have bought the AV cable from an Apple store, and I thought I would be able to use it fairly easily.

    Just plug the cable into the dock connector on the iPhone and the other end into your TV (making sure the right colours go with the right colours ) and check in Settings>iPod that widescreen is either on/off and that the correct TV Signal option is selected PAL/NTSC then change the TV's input to whatever the signal input should be (Component 2 on my TV) and voila you play movie it shows on TV (hopefully) it should really be plug and play tough it's worth checking you have the right cable for the job Component/Composite

  • 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.

  • Jsf data table component + print null cell

    I am using the jsf data table component and binding the column values to a backing bean.
    <h:dataTable binding="#{backing_showDifferences.dataTable2}"
    id="dataTable2">
    <h:column binding="#{backing_showDifferences.userColumn1}"/>
    <h:column binding="#{backing_showDifferences.userColumn2}"/>
    <h:column binding="#{backing_showDifferences.userColumn3}"/>
    </h:dataTable>
    - some code from my showDifferences.java
    HtmlOutputText column1Text = new HtmlOutputText();
    vb =
    FacesContext.getCurrentInstance().getApplication().createValueBinding("#{users.uclass}");
    column1Text.setValueBinding("value", vb);
    usercolumn1.getChildren().add(column1Text);
    HtmlOutputText column2Text = new HtmlOutputText();
    vb =
    FacesContext.getCurrentInstance().getApplication().createValueBinding("#{users.ue1}");
    column2Text.setValueBinding("value", vb);
    usercolumn2.getChildren().add(column2Text);
    HtmlOutputText column3Text = new HtmlOutputText();
    vb =
    FacesContext.getCurrentInstance().getApplication().createValueBinding("#{users.ue2}");
    column3Text.setValueBinding("value", vb);
    usercolumn3.getChildren().add(column3Text);
    ResultSetDataModel dataModel = new ResultSetDataModel();
    dataModel.setWrappedData(rs);
    dataTable2.setValue(dataModel);
    The raw HTML:
    <table id="form1:dataTable2" class="iuptable" border="1">
    <thead>
    <tr>
    <th scope="col">Heading 1</th>
    <th scope="col">Heading 2</th>
    <th scope="col">Heading3</th>
    </tr>
    </thead>
    <tbody>
    <tr>
    <td>some data in this column</td>
    <td>X</td>
    <td></td>
    </tr>
    <tr>
    <td>Some more data in this row</td>
    <td>X</td>
    <td></td>
    </tr>
    </tbody>
    </table>
    My problem is this...in the raw HTML the <td></td> tag is not formatted nicely on my table output. I have lines around my entire table and each cell within it. When the <td></td> prints there are no lines. I am new to the JSF table data component, but if I were writing some JSP or servlet code I would check that if value was null I would append an &nbsp to the <td> tag (ex. <td>&nbsp</td>) and the table would be formatted properly. The backing bean that I am binding to is pulling the data from a database table...so my sql looks like this:
    SELECT uclass, ue1, ue2 from table1; my problem is when ue1 or ue2 is a null value.
    Any ideas would be greatly appreciated!

    Hi,
    the h:dataTable belongs to the JSF Reference Implementation from Sun, not to Oracle ADF Faces. The rendering is within this component set and I suggest to report your issue on one of the SUN forums (http://forum.java.sun.com/forum.jspa?forumID=427) as we have no handle to e.g. fix an issue if it exists in the component set.
    Frank

  • Render Related -JSF Third party Component

    Hai All
    I am having doubt regarding JSF Third party component like Jmaki ,MyFaces or something like that . How the third party component match with JSF life cycle even though there is no java classes for managing and rendering the Third party component . what i basically mean to say is if we use <h:inputText> in our JSF page , the inputText component will managed by many java class like UIInput.class and HtmlInputText and InputTextRender and so on. next if we use dojo.dropdowndatepicker ,there is component for managing this component like UIDate, HtmlData .
    could you tell me how third party component working without any problem.
    Thanks for advance
    Selvakumar.k

    If you look in the jar files for the libraries, you will find a faces-config.xml file containing such configurations.

  • Why JSF & When to use JSF?

    Hi Experts,
    I am new to JSF and i am studying that now. I have some basic questions.
    1. Why JSF and When to use JSF means What is the right requirement or situation to use JSF?
    2. Studied that JSF is basically a UI driven framework and developed to provide & support for UI component model. If that is the case, each UI components(Textfield, drop-down, etc..) in the web page is coupled to server-side components and for each validation or events, is the page submitted to server and come back?
    3. What are the other benefits i get compared to Struts and JSP if i use JSF?
    Please provide your experience.
    Thanks,.
    Edited by: MouliOnTech on Mar 6, 2009 3:02 AM

    Depends on how you code the JSF page and which component library you use.
    Standard JSF components doesn´t support asynchronous requests, so the validation will only happen when you submit the form to the server (either by pressing the submit button or by Javascript´s form.submit). But there are also Ajaxical JSF component libraries out which can validate asynchronously based on the (Javascript) events. For example RichFaces/Ajax4jsf.

  • Problem using trinidad 2.0 and facelets

    Hi everyone!!!
    I am facing problem using Trinidad 2.0 components with facelets. I am using Tomcat 6.0 server , 1.6_20 jdk with jre6. I am using springsource tool suite as an IDE.
    My problem is regarding usage of facelets with trinidad component library. I am trying to run *<tr:panelTabbed>* component of TRINIDAD 2.0 on *.jsp* as well as *.xhtml*. If I run my jsp , I am able to used panel tab fully like switching between two tabs. Same code I have added in my .xhtml page in the same project under *<ui:composition>* tags. I am successfully able show the component on the screen , but I am not able to switch between the two tabs. Here are the list of libs that have added to the project.
    commons-beanutils-1.7.0.jar,commons-codec-1.3.jar,commons-collections-3.2.jar,commons-digester-1.8.jar,commons-discovery-0.4.jar,
    commons-el.jar,commons-fileupload.jar,commons-logging-1.1.1.jar,jsf-facelets.jar,jstl.jar,myfaces-api-2.0.1.jar,myfaces-impl-2.0.1.jar,
    trinidad-api-2.0.0-alpha-2.jar,trinidad-impl-2.0.0-alpha-2.jar
    index.jsp
    <%@taglib uri="http://myfaces.apache.org/trinidad" prefix="tr"%><html>
    <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
    <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
    <head>
    <title>Your first JSF Application</title>
    </head>
    <body bgcolor="white">
    <f:view>
         <tr:document>
              <h:form>
                   <tr:panelTabbed position="above">
                        <tr:showDetailItem text="Account">
                             <tr:panelBox text="Account Information Details"
                                  inlineStyle="width: 100%;">
                                  <tr:panelList inlineStyle="width: 100px;">
                                       <tr:panelHorizontalLayout inlineStyle="height:100px;">
                                            <f:facet name="separator">
                                                 <tr:spacer width="100" height="100" />
                                            </f:facet>
                                            <tr:outputText value="Account Number" styleClass="AFFieldText" />
                                            <tr:outputText value="Effective Date" styleClass="AFFieldText" />
                                            <tr:outputText value="Expiration Date" styleClass="AFFieldText" />
                                       </tr:panelHorizontalLayout>
                                       <tr:panelHorizontalLayout inlineStyle="height:100px;">
                                            <f:facet name="separator">
                                                 <tr:spacer width="100" height="100" />
                                            </f:facet>
                                            <tr:outputText value="#{accDet.accountNumber}"
                                                 styleClass="AFFieldText" />
                                            <tr:outputText value="#{accDet.effectiveDate}"
                                                 styleClass="AFFieldText" />
                                            <tr:outputText value="#{accDet.expirationDate}"
                                                 styleClass="AFFieldText" />
                                       </tr:panelHorizontalLayout>
                                       <tr:separator />
                                       <tr:panelHorizontalLayout inlineStyle="height:100px;">
                                            <f:facet name="separator">
                                                 <tr:spacer width="100" height="1" />
                                            </f:facet>
                                            <tr:outputText value="Address" styleClass="AFFieldText" />
                                            <tr:outputText value="Fax" styleClass="AFFieldText" />
                                       </tr:panelHorizontalLayout>
                                       <tr:panelHorizontalLayout inlineStyle="height:100px;">
                                            <f:facet name="separator">
                                                 <tr:spacer width="100" height="1" />
                                            </f:facet>
                                            <tr:outputText value="#{accDet.address}"
                                                 styleClass="AFFieldText" />
                                            <tr:outputText value="#{accDet.fax}" styleClass="AFFieldText" />
                                       </tr:panelHorizontalLayout>
                                  </tr:panelList>
                             </tr:panelBox>
                        </tr:showDetailItem>
                        <tr:showDetailItem text="Insured">
                             <tr:panelHeader text="Header 2">
                                  <tr:panelFormLayout>
                                       <tr:inputText label="Text1" />
                                       <tr:inputText label="Text2" />
                                       <tr:inputText label="Text3" />
                                  </tr:panelFormLayout>
                             </tr:panelHeader>
                        </tr:showDetailItem>
                   </tr:panelTabbed>
              </h:form>
         </tr:document>
    </f:view>
    </body>
    </html>
    guess.xhtml
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml"
         xmlns:ui="http://java.sun.com/jsf/facelets"
         xmlns:h="http://java.sun.com/jsf/html"
         xmlns:tr="http://myfaces.apache.org/trinidad"
         xmlns:f="http://java.sun.com/jsf/core">
    <body bgcolor="white">
    <f:view>
         <tr:document>
    <h:form>
         <tr:panelTabbed>
              <tr:showDetailItem text="Tab 1"></tr:showDetailItem>
              <tr:showDetailItem text="Tab 2"></tr:showDetailItem>
         </tr:panelTabbed>
    </h:form>
    </tr:document>
    </f:view>
    </body>
    </html>
    web.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
         xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
         id="WebApp_ID" version="2.5">
         <display-name>Demo_ProtoType</display-name>
         <filter>
              <filter-name>trinidad</filter-name>
              <filter-class>org.apache.myfaces.trinidad.webapp.TrinidadFilter</filter-class>
         </filter>
         <filter-mapping>
              <filter-name>trinidad</filter-name>
              <servlet-name>faces</servlet-name>
         </filter-mapping>
         <context-param>
              <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
              <param-value>client</param-value>
         </context-param>
         <listener>
              <listener-class>
                   org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
         </listener>
         <servlet>
              <servlet-name>Faces Servlet</servlet-name>
              <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
              <load-on-startup>1</load-on-startup>
         </servlet>
         <servlet-mapping>
              <servlet-name>Faces Servlet</servlet-name>
              <url-pattern>*.xhtml</url-pattern>
         </servlet-mapping>
         <servlet>
              <servlet-name>resources</servlet-name>
              <servlet-class>org.apache.myfaces.trinidad.webapp.ResourceServlet</servlet-class>
         </servlet>
         <servlet-mapping>
              <servlet-name>resources</servlet-name>
              <url-pattern>/adf/*</url-pattern>
         </servlet-mapping>
         <context-param>
              <param-name>org.apache.myfaces.trinidad.ALTERNATE_VIEW_HANDLER</param-name>
              <param-value>org.apache.myfaces.trinidadinternal.facelets.TrinidadFaceletViewHandler</param-value>
         </context-param>
         <context-param>
              <param-name>org.apache.myfaces.trinidad.FACELETS_VIEW_MAPPINGS</param-name>
              <param-value>*.xhtml</param-value>
         </context-param>
    </web-app>
    faces-config.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <faces-config 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/javaee/web-facesconfig_1_2.xsd"
         version="1.2">
         <application>
              <default-render-kit-id>org.apache.myfaces.trinidad.core</default-render-kit-id>
         </application>
         <managed-bean>
              <managed-bean-name>accDet</managed-bean-name>
              <managed-bean-class>com.csc.Account.AccountDetail</managed-bean-class>
              <managed-bean-scope>session</managed-bean-scope>
         </managed-bean>
    </faces-config>Following warning is coming on server start up
    java.lang.ClassNotFoundException: org.apache.myfaces.trinidadinternal.facelets.TrinidadFaceletViewHandler
         at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1484)
    PLEASE LET ME KNOW IF ANYONE NEED THE .WAR file .I can send it over mail. Please hrlp me out !!! I have literally tried everything.This is the only HOPE

    Hi gimbal2 ,
    thanks for your prompt response.
    I deleted jsf-facelets.jar from the lib.
    Also I removed      <context-param>
              <param-name>org.apache.myfaces.trinidad.ALTERNATE_VIEW_HANDLER</param-name>
              <param-value>org.apache.myfaces.trinidadinternal.facelets.TrinidadFaceletViewHandler</param-value>
         </context-param>
         <context-param>
              <param-name>org.apache.myfaces.trinidad.FACELETS_VIEW_MAPPINGS</param-name>
              <param-value>*.xhtml</param-value>
         </context-param>Now that error has gone .But I am still not able to switch between the tabs for .xhtml page but it is working fine for .jsp page.
    For .xhtml page , on clicking on the tab, console is showing something like below
    Aug 17, 2010 9:20:49 PM org.apache.myfaces.trinidad.component.UIXShowDetail broadcast
    WARNING: Event org.apache.myfaces.trinidad.event.DisclosureEvent[phaseId=INVOKE_APPLICATION(5),component=CoreShowDetailItem[UINodeFacesBean, id=j_id957384125_39108532],expanded=true] was delivered to a showDetail already in that disclosure state.

  • Problem with attributes in custom component

    Hi All,
    I am creating a simple jsf PanelGrid custom component....in that component I am adding two new attributes....
    when I use that tag in my jsf application it is rendering fine in the client side....but the parent class that is PanelGrid component's attributes are not inheriting to my custom panelgrid....
    can any one tell me how can I use the attributes of the super class PanelGrid??
    Thanks...

    Have you configured the attributes in the tag library descriptor?

Maybe you are looking for

  • Itunes says I don't have an internet connection but I can access the internet.  I turned my firewall off.  How do I get onto itunes store

    I can't access my itunes store, it says I don't have an internet connection but I do.  I tried updating to the newest version of itunes, turned off my firewall, checked to make sure itunes was allowed in my internet options.  what else can i do?

  • Could you please answer this questions ?

    could you please answer this questions ...... 2. What can you do with the DBMS_LOB package? A. Use the DBMS_LOB.WRITE procedure to write data to a BFILE. B. Use the DBMS_LOB.BFILENAME function to locate an external BFILE. C. Use the DBMS_LOB.FILEEXIS

  • Captivate 4 Question Pool Slides Show Ghosts

    Random question slides display captions from previous slides when I publish to Flash 8-10. Publishing to Flash 7 or using the same questions (but not as random questions) cures the problem. The captions appear on all but one random question slide (8

  • What, *exactly*, does a factory reset do?

    My Thinkpad T430, less than a year old, is having issues - corrupted .dll files, Windows Update not working, all sorts of fun stuff. I am waiting on someone to e-mail me clean copies of the .dlls I need BUT am concerned that that won't fix everything

  • Shared Ipad

    My wife and I share an ipad. Can we BOTH have email account in iCloud (i.e. BOTH have our contacts, mail etc transfer over)