Results 1 to 4 of 4

Thread: Problem with Date

  1. #1
    Sencha User
    Join Date
    Sep 2010
    Posts
    121

    Default Problem with Date

    Guys, i am with a problem.
    I am not able to view in the page the date.
    I get this date of database from json.
    I want to view the date in my data.field.
    I tried to use the dateFormat="dd/MM/yyyy", mas no deu certo.
    It appears [object Object].
    Could someone help me?

  2. #2
    Sencha User Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,245

    Default

    Post more information.

    1. How does your server format the data in the response?
    2. How did you configure your field type and dateFormat?
    3. How did you configure your column renderer?

  3. #3
    Sencha User
    Join Date
    Sep 2010
    Posts
    121

    Default

    Quote Originally Posted by Condor View Post
    Post more information.

    1. How does your server format the data in the response?
    2. How did you configure your field type and dateFormat?
    3. How did you configure your column renderer?
    I am working with java.
    I used type Date and it was work.
    I changed for String and now the date appears as 2010-06-07 14:10:32.0.
    I want that the date it appears this format 07/06/2010.
    How can I configure for this format?

  4. #4
    Sencha User Condor's Avatar
    Join Date
    Mar 2007
    Location
    The Netherlands
    Posts
    24,245

    Default

    1. Have your server send the date formatted with: new SimpleDateFormat("yyyyMMddHHmmss").
    2. Configure your field with: type: 'date', dateFormat: 'YmdHis'.
    3. Configure your column with: renderer: Ext.util.Format.dateRenderer('d-m-Y');

Similar Threads

  1. problem with Date
    By Cyberangel67 in forum Ext 3.x: Help & Discussion
    Replies: 2
    Last Post: 29 Aug 2010, 4:18 PM
  2. How can select future day date only not a past date and current date
    By painter in forum Ext 2.x: Help & Discussion
    Replies: 2
    Last Post: 6 Apr 2009, 10:11 PM
  3. How to set month start date month end date default in date field
    By frank_ash in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 17 Oct 2008, 6:59 AM
  4. Date value null problem
    By payal in forum Ext 1.x: Help & Discussion
    Replies: 1
    Last Post: 14 Sep 2007, 1:33 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •