7

The SSRS report works fine if the user's date format is something like:

MM/dd/yyyy

But if the date format is different, the date parameter is "cleared out" automatically after being set, IT DISAPPEARS, for example, this fails

enter image description here

Again, if you put a value in that "End Date" parameter, it automatically disappears.

Things I have tried:

Setting the report's Language property to: "en-us", User!Language and blank.

So clearly SSRS thinks the date being input is invalid and it clears it out.

What do I need to do to make this work?

The One
  • 4,560
  • 5
  • 36
  • 52
  • The display format of parameters is based on the browser, not the report. When I view a report in my preferred browser, I have to use `dd/MM/yyyy` for example. If `MM/dd/yyyy` isn't correct, then it's the browser language that you need to change, not the report's. You wouldn't be able to put a value like the string `"End Date"` in the parameter `EndDate`, as that image clearly shows that it requires a date; the string `"End Date`" is not a valid date. *Note; Chrome, in my experience, just ignores the user's language setting and uses `MM/dd/yyyy`.* – Thom A Apr 16 '19 at 16:11
  • So, do you have to tell your users to change their date format on their computers/browsers? – The One Apr 16 '19 at 16:42
  • No, @TheOne , I assume they have it set to the input method they prefer. If not, then it's up to them to change it. Of course if they tell me the report is "wrong" I'll guide them on how to change their settings to "fix" it; but it's up to them to decide their language. – Thom A Apr 16 '19 at 16:48
  • 1
    Chrome does ignore Windows - it has it's own Language settings. – Mike Honey Apr 27 '19 at 07:46
  • 1
    @MikeHoney i mentioned you in my answer since you have posted helpful comments in MSDN forum – Hadi Apr 27 '19 at 10:44

1 Answers1

3

Possible workarounds

The following workarounds may solves this issue.

(1) Handling the parameters date format

If you do not want to edit all code, then it is easier to force the parameter data string format, make sure that all parameters passed to TO_DATE() function are in following format (or try to change the default date format from the OS regional settings):

dd-MMM-yyyy   example: 01-AUG-2019

(2) Forcing Culture info by editing ReportViewer.aspx

You can edit the ReportViewer.aspx file is located in the SQL Server reporting services directory, and force the culture info used within reports. Check out the following question it will give you more details:

(3) Changing the browser language settings

Check the following link (read Mike Honey and Nick St Mags answers):


You can check the following answer, it contains many workarounds that may give you some insights:

Hadi
  • 36,233
  • 13
  • 65
  • 124