[CLOSED] DateField Format Problem

  1. #1

    [CLOSED] DateField Format Problem

    Hi all,

    After upgrading my app server from Windows Server 2008 R2 to Windows Server 2012 R2, datefield's format is changed to j.n.Y.

    I should be d.m.Y. All other localization configurations are ok for Turkish but whatever I do, I can't change this to d.m.Y.

    I am using 3.2.1 version of Ext.Net.

    Thanks,
    Vzx
  2. #2
    Hello! This may have to do with the regional settings on your new windows server installation. If you can't change region settings on your windows server, you need to specify the culture/region settings you want whenever you need to use date/time display instructions (once per function/thread).

    This article may help you with it, ensuring you get the globalization settings you need: How to: Set the Culture and UI Culture for Windows Forms Globalization.

    I hope this helps!
    Fabrício Murta
    Developer & Support Expert
  3. #3
    Hi Fabricio,

    I changed regional settings. There is no problem with it.
    I also set Culture and UICulture in my application. As I said there is not problem with other settings. The only problem is datefield's format.

    Can you check this with setting Culture and UICulture settings?

    Thanks,
    Vzx
  4. #4
    Hello @vzx!

    It is not clear to me how to reproduce your issue at our end at all. You saying that just by changing to windows server 2012 makes the date format in Ext.Net.DateField change, and you can't specify the format setting cultureInfo?

    Changing the OS shouldn't change the display format on the date field in first place, as it uses resourceManager's locale setting (which defaults to en-US) so it is not clear your use case.

    If I just define a simple dateField I can easily determine its display format with:

    <ext:DateField runat="server" Format="d.m.Y" />
    But as you stated, you changed your OS and the date format changed. So what seems to be the case here is you are feeding a System.DateTime from code behind which gets scrambled to the client side and misplaces the fields of the Ext.Net.DateField
    component. And how exactly you are doing this seems to be quite relevant in order to understand what's happening on your side.

    That said, can you provide us a working example that illustrates and reproduces your issue and use case with the DateField component?
    Fabrício Murta
    Developer & Support Expert
  5. #5
    Hi,

    I found the problem. In 2012 I set ResourceManager's Locale property to "tr". I think this was a workaround for a bug at that time. After removing this code, the problem is gone.

    Thanks,

    Vzx
  6. #6
    Hello @vzx! Glad to hear back from you and that you finally found the reason it broke! Thanks for sharing the outcome!
    Fabrício Murta
    Developer & Support Expert

Similar Threads

  1. DateField Format
    By Timothy in forum 1.x Help
    Replies: 4
    Last Post: Jun 07, 2013, 5:42 PM
  2. [CLOSED] DateField data format problem
    By asztern in forum 1.x Legacy Premium Help
    Replies: 5
    Last Post: Oct 08, 2010, 9:36 PM
  3. DateField format
    By flaviodamaia in forum 1.x Help
    Replies: 0
    Last Post: Jul 01, 2009, 11:30 AM
  4. DateField Format
    By BLOZZY in forum 1.x Help
    Replies: 1
    Last Post: May 18, 2009, 3:41 PM
  5. Replies: 3
    Last Post: Mar 17, 2009, 9:42 AM

Tags for this Thread

Posting Permissions