After spending many hours trying to understand this "glitch" of the new Events Module, I have finally reached the following results:
Setup:
- Windows Server 2003 R2 .NET 3.5 SP1, all up-to-date + SQL Server 2005
- DNN v5.5.0 and v5.5.1
- Events Module 5.1.4 (which is the only version functioning under DNN 5.5.x)
- All Browsers
I) The malfunctioning
a) When a locale other than en-US is configured as the portal default, or as the default for a specific user with editing permissions over the Events Module, there is an error upon adding a new event (sign plus button over the upper right on default month view).
b) The text of the error varies, but is mainly one of the following:
- "An error has occurred. Error: is currently unavailable."
- "Error: is currently unavailable. DotNetNuke.Services.Exceptions.ModuleLoadException: String was not recognized as a valid DateTime. ---> System.FormatException: String was not recognized as a valid DateTime. at System.DateTimeParse.ParseExact(String s, String format, DateTimeFormatInfo dtfi, DateTimeStyles style) at DotNetNuke.Modules.Events.EditEvents.ConvertDateStringstoDatetime(String strDate, String strTime, String strTimeSuffix, Boolean useSuffix) at DotNetNuke.Modules.Events.EditEvents.UpdateProcessing(Int32 ProcessItem) at DotNetNuke.Modules.Events.EditEvents.updateButton_Click(Object sender, EventArgs e) --- End of inner exception stack trace ---"
II) The investigation
a) I have walked many paths trying to find a workaround for this thing. Most are not worth detailing, such as going back to an intent to install on DNN v5.5.x an incompatible Events Module v5.0.3. I did even build specific language packs for the Events Module, but those intents ended all showing the same error. And thus...
b) This lead me to focus on the date and time parser from the Events Module. Since opening the source package and debugging was not an option, then trying to identify what things work and what did not was acceptable.
c) What works? Dates and Time en-US formatted, of course. But also Dates with different formats within certain rules:
-> MM/dd/yyyy + HH:mm:ss
-> dd/MM/yyyy + HH:mm:ss
-> dd/MM/yyyy + H:mm:ss
-> dd/MM/yyyy + hh:mm:ss tt (where tt is "AM" or "PM")
...and many others.
d) What does not work?
-> dd/MM/yyyy + hh:mm:ss tt (where tt is "a.m." or "p.m.")
...and apparently any Date combination, but Time with this specific "tt" text formatting.
e) Which cultures are affected? AFAIK:
- English (New Zealand)
- Spanish (all countries except España, Ecuador and Chile).
...there might be others which I am not aware of.
III) The solutions
a) What comes first to my mind is editing the source code and proposing a code patch, but unfortunately I cannot install VS2010 at this time, so that task is yet the first undone step to be done.
b) Editing the default Time settings on Windows Server 2003 R2 with all patches and .NET Frameworks, and up to date and everything. Impossible, unthinkable, but impossible. I tried everything, from the standard option of the Control Panel to editing IIS, the registry throughout all Keys, and things, though they seem to have changed, upon restarting or whatever, they stick to the previous values. I googled this issue and it does happen with W2K3 and XP. Of course, Admin privileges and everything.
c) Adding a New Language or Installing a New Language Pack, that has every other culture combination coinciding with the needed one but the "correct" Time setting, without tt being "a.m." or "p.m.".
d) If c) is not possible, which did happen to me, building a "custom" Language Pack, containing the Text Resources of the desired language, but the culture settings of a working one.
Both c) and d) solutions proved to solve the issue.
IV) Given all known issues related to DNN v5.5.x and its faulty handling of cultures, I honestly do not know if this issue is to be logged under the Events Module or under DNN itself. Thus...
a) The issue is posted for the Events Module forum.
b) The issue is posted for DNN Localization forum.
c) Cannot create the issue under Gemini, it keeps telling me "Provide information to create a new issue", which of course I am providing IMHO.
Saludos,
Alejandro.
|