Bug Report T312104
Visible to All Users

Dates in a custom format are not updated in day headers if the cxFormatController.UseDelphiDateTimeFormats property is set to True

created 9 years ago (modified 9 years ago)

[DevExpress Support Team: CLONED FROM B203112: Dateseparator incorrect if date format is German]
The Problem is still present with DevExpress VCL v14.x controls under Delphi XE7:

Calling TcxSchedulerDateTimeHelper.DayToStr(now, 0, false) gives 'Freitag, 13/ November' on a German language system
while DateToLongDateStr(now) gives correctly 'Freitag, 13. November 2015'

Calling cxFormatController.UseDelphiDateTimeFormats := true; beforehand also corrupts the call to DateToLongDateStr. Both functions use cxGetDateFormat().

It seems like the date formatting functions inside cxDateUtils.pas do not replace the special character '/' in the format strings with the current user's DateSeparator.

The other linked issue B203525 is not the same problem.

Just another remark: I tried your current Feature Demo and the dates in the Scheduler are also wrong.

Comments (1)
DevExpress Support Team 9 years ago

    Thank you for your report. I have reproduced this behavior with German settings in modern IDEs and forwarded this ticket to our developers for research.

    Answers approved by DevExpress Support

    created 9 years ago

    We have fixed the issue described in this ticket and will include the fix in our next maintenance update. To apply this solution before the official update, request a hotfix by clicking the corresponding link for product versions you require.

    Note: Hotfixes may be unavailable for beta versions and updates that are about to be released.

      Comments (2)

        I'm sorry, but your last update didn't fix the issue. After installing v15.2.3 I can still find the wrong separators in our application. Thus I installed your latest demos and there the problem is also present (see screenshot attached).

        DevExpress Support Team 9 years ago

          Hello,

          In the context of this ticket, we have fixed the issue that prevented the solution from the B203525 ticket from working correctly. I mean the following code that can help you display correct German dates:

          Code
          uses ... cxFormats, cxDateUtils, ... initialization FormatSettings.ShortDateFormat := cxGetLocalShortDateFormat; FormatSettings.LongDateFormat := cxGetLocalLongDateFormat; cxFormatController.GetFormats;

          We understand that the current Scheduler behavior with German date formats need to be changed, but for now we have not found a way to do so without breaking other regional formats. We are going to continue our research and will try to find a solution in the context of the T340069 ticket.

          Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

          Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.