Wednesday, March 21, 2012

Datetime parameter problems

Hi everyone

I have been reading another thread about this subject, but didn't get much useful info from it.

I have a datetime parameter on my report that is set to today() by default.

I use the User!Language to ensure that dates are formatted correctly (my end-users are Danish, Spanish, English)

Everything works fine on the preview tab, but when I access the deployed report through a link to the report server on a HTML-page the formatting of the date becomes US-style. This leads to further problems, as the report can not be processed because another format is expected (probably due to the User!Language settings on the report - in my case Danish).

I need to find a solution, that does not remove the dynamics of being able to run in different language settings (I saw in the other thread that one solution could be to hard code a statement with a specific language setting - that is not an option for me).

Hope someone can help

Maybe I should add that the problem occurs the first time I try to change the date to another date than the default date by using the calendar icon. Then the date is changed to US-format...|||Your regional settings must be US on the PC with IE.
Put the User!Language in a textbox to see what it thinks your settings are.

how to change the settings:
http://www.endnote.com/support/helpdocs/Changing%20Regional%20Settings%20in%20Windows%20XP.pdf
http://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/int_pr_date.mspx?mfr=true

Can someone from MSFT post a pinned message showing how to resolve date format issues?

This one seems to come up at least once a day|||

My settings are not US - but Danish: da-DK

If I view the report once with the default date (that is formatted correct) - I have no problems - but if I try to change the date to another date e.g. yesterday - then the format is changed from 19-06-07 (DK) to 06/19/2007 (US) and I immediately get an error saying:

  • The value provided for the report parameter 'fraDato' is not valid for its type. (rsReportParameterTypeMismatch)
  • |||

    I have the exact same problem.

    It appears it has been introduced with SP2.

    no matter what regional setting you use it always reverts the selection to en-US, and then generates an error.

    The error must be generated by some internal validation on the DatePicker.

    If anyone finds a fix please let me know

    |||This is a problem with that control, it cannot use anything except US date format. The simple work around when using other cultures is to run the report instead of using the Preview tab, the web version of that control does not suffer from that problem.|||That is not correct - I only get the error when I run the report in a browser!!!|||

    Sorry, i didn't read what you said properly. In your case, make sure your browser language settings are set correctly (IE defaults to en-US), and the regional settings on the report server and in the report itself are set correctly.

    BTW, the en-US format of the date picker control in the preview tab *was* an issue until just recently, it has come to my notice the MS have released some hotfixes to SP2 that address the issue: http://support.microsoft.com/kb/936305

  • No comments:

    Post a Comment