calendar problem

UI Components for JSF
Post Reply
usamagdy
Posts: 22
Joined: 13 Mar 2011, 08:19
Contact:

13 Mar 2011, 08:29

i'm tring to display the calendar but no thing come up
<h:form prependId="false" >
<h:panelGrid columns="4">

<div>
<p:calendar id="cner9sma4" showOn="button" style="display:inline-block;width:190px;background-color: yellow;" />
<p:calendar id="rr9tys4" mode="inline" />
<p:calendar id="rr9tys4uj"/>

</div>
</h:panelGrid >
</h:form>

i'm working jsf2 +primefaces-2.2.RC2
Certified Sun Java programmer 6
Certified IBM DB2 Associate
Certified IBM Associate Developer
Certified IBM Application Developer.
Certified IBM System Administrator:

gcameo
Posts: 63
Joined: 02 Mar 2011, 07:38

13 Mar 2011, 08:55

<h:panelGrid columns="4">

<div>
<p:calendar id="cner9sma4" showOn="button" style="display:inline-block;width:190px;background-color: yellow;" />
<p:calendar id="rr9tys4" mode="inline" />
<p:calendar id="rr9tys4uj"/>

</div>
</h:panelGrid >
You have only one item in your 4 column grid. Dont know if that is what your intension is.

Also how many calendars are you trying to display, 1 or 3?

Also you dont have a value for the calendar. The documentation says value must be a date so i suppose the component will not try and help you if you dont supply one. declare one in your jsf bean and bind it and lets see if that works first
Primefaces version: 3.0-SNAPSHOT

JSF implementation: Mojarra 2.0.4

Server: Glassfish 3.1-beta

usamagdy
Posts: 22
Joined: 13 Mar 2011, 08:19
Contact:

13 Mar 2011, 09:42

I taked snapshot form my code


<p:calendar id="cner9sma4" showOn="button" style="display:inline-block;width:190px;background-color: yellow;" disabled="#{customer.disabled}" value="#{customer.mainCust.contactIDDocIssueDate}" />


private java.util.Date contactIDDocIssueDate;

public java.util.Date getContactIDDocIssueDate() {
return contactIDDocIssueDate;
}

public void setContactIDDocIssueDate(java.util.Date contactIDDocIssueDate) {
this.contactIDDocIssueDate = contactIDDocIssueDate;
}
Certified Sun Java programmer 6
Certified IBM DB2 Associate
Certified IBM Associate Developer
Certified IBM Application Developer.
Certified IBM System Administrator:

usamagdy
Posts: 22
Joined: 13 Mar 2011, 08:19
Contact:

13 Mar 2011, 09:44

i want to display any of them
Certified Sun Java programmer 6
Certified IBM DB2 Associate
Certified IBM Associate Developer
Certified IBM Application Developer.
Certified IBM System Administrator:

gcameo
Posts: 63
Joined: 02 Mar 2011, 07:38

13 Mar 2011, 10:38

private java.util.Date contactIDDocIssueDate;
is it possible that this is null

use and lets see if that works

Code: Select all

    @PostConstruct
    public void init()
    {
        contactIDDocIssueDate= new Date();
    }
Primefaces version: 3.0-SNAPSHOT

JSF implementation: Mojarra 2.0.4

Server: Glassfish 3.1-beta

usamagdy
Posts: 22
Joined: 13 Mar 2011, 08:19
Contact:

13 Mar 2011, 11:01

thanks i found the problem
the problem was in skin.css
Certified Sun Java programmer 6
Certified IBM DB2 Associate
Certified IBM Associate Developer
Certified IBM Application Developer.
Certified IBM System Administrator:

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 13 guests