facebook

New MyEclipse JSF problems seeing defined var

  1. MyEclipse IDE
  2.  > 
  3. Java EE Development (EJB, JSP, Struts, XDoclet, etc.)
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #276784 Reply

    drambo95
    Member

    Hello,
    I have spent a couple of days trying to figure this one out, and I think either the project is getting set up wrong or I am doing something weird. I first set up a project with Spring, Hibernate and JSF got everything working in Hibernate and returning rows but in JSF, I was setting a datatable and named the var. When I tried to use this with outputtext and value it can’t see the var from the datatable.

    So I thought its me, I did another project only importing jsf and followed the tutorial for login, after importing the bundle, I can’t see that var either. It says can’t be found and ctrl space doesn’t show vars only beans

    Here is my jsp from the tutorial
    <body>
    <f:view>
    <h:form>
    <f:loadBundle basename=”com.sempra.message.MessageBundle” var=”bundle”/>

    <h:dataTable id=”data”
    var=”atom”
    value=”#{LoginUser.bob}”
    >
    <h:column>
    <f:facet name=”header”>
    <f:verbatim>ID</f:verbatim>
    </f:facet>
    <h:outputText value=”#{atom.crap1}”></h:outputText>
    <h:outputText value=”#{bundle}”></h:outputText>
    </h:column>
    </h:dataTable>
    </h:form>
    </f:view>
    </body>
    </html>

    I also put in a list from a bean and cant see that var either, can anyone help me?

    Cheers
    Devlin

    #276807 Reply

    Riyad Kalla
    Member

    Devlin,
    Unfortunately this warning is just a red-herring in the editor. The JSP parser isn’t aware of the “var” field for datatable that generates a page-scoped variable, so the validator gets down to your outputText and gets all confused where the “atom” reference came from.

    It’s been on our TODO list for a while. I am going to push the dev team forward and see if we can get this fixed.

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: New MyEclipse JSF problems seeing defined var

You must be logged in to post in the forum log in