How do you control the display of the time and dates on the iNotes Calendar control in an XPage? I would like to have the times shown using the 12 hour format hh:mm AM and the date to use MMM dd, yyyy.
Thank you.
The date and time format for iNotes Calendar is defined in language files for the most common languages. These language files are specific for iNotes Calendar.
They are stored in com.ibm.xsp.extlib.domino_x.x.x.xxxxxxxx-xxxx.jar file in folder DominoServerPath\data\domino\workspace\applications\eclipse\plugins.
If you unpack the jar file (it's just a zip file) you'll find a folder resources\web\dwa\date\nls and there the language specific subfolders like de, en, en-gb, en-ie and en-us. The date and time format is definied in that subfolders in file calendar.js.
This file starts e.g. for en-us with the lines:
Surprisingly, the date and time format is not right for the US en-us. Same for en, en-gb and en-ie. I'd call it a bug or at least a wrong packaging.
If you change the time format line to D_DTFMT_TIME0: "hh:mmt" then you get your 12 hour time format with am/pm.
Close to setting D_DTFMT_TIME0 are all the other settings for date and time formatting.
So, change all en languages files with the appropriate values, save them back to the jar file and restart the Domino server.
Just for further research: the date and time values get formatted with the help of ...jar\resources\web\dwa\date\dateFormatter.js.
Related
having trouble with date formats in CSV file format(Excel)
I want the date in "YYYY-MM-DD hh:mm " format and I need it in .CSV format.
When reopening the file, the date format gets changed and it looks like "MM-DD-YYYY hh:mm".
Does anyboy know how I can retain my desired date format when saving the file as .CSV?
Thank you!
Use the format YYYYMMDD in all CSV files, which doesn't convert to date in Excel or you can do one of the below things
Use a Custom format, rather than one of the pre-selected Date formats, the export to CSV will keep your selected format. Otherwise it defaults back to the US format
Place an apostrophe in front of the date and it should export in the correct format. Just found it out for myself, I found this thread searching for an answer.
Change the date and time settings for your computer in the "short date" format under calendar settings. This will change the format for everything yyyy-mm-dd or however you want it to display; but remember it will look like that even for files saved on your computer.
When I preview an xlsx file in gmail the cells of dates display as integers. For example the date (formatted as dd/mm/yyyy) 20/06/2018 is displayed 43271. The same holds when opening the file by Google Spreadsheet (GS) because the date cells are identified as number formatted.
Tried to change Gmail language settings but with no effect.
My question: Is there a fix to enable a correct date format in gmail preview without having to download the file and open it with Excel or Calc?
An answer that further explains why GS is behaving so will be more appreciated (I am not seeking an answer that explains the integer is the number of days starting from a given date but technically explains why GS fails to display the suitable date).
This problem is driving me crazy. I'm exporting a csv file from our email send platform to a network drive. One of the fields is a datetime field. When you view it in our email send platform's UI, it looks fine, as in the first two entries here:
And when I open up the raw file in a text editor it displays them as:
Again, looks fine.
However, when I open the CSV up in Excel, it changes one to 24H and one to an AM/PM format.
Why is it doing this and how can I stop it?
Edit: I've just noticed it adds the AM/PM to ones which happened where it doesn't end in 00 seconds.
I have a CSV file that contains a few date columns. It was created with the US format of dd/mm/yyyy. I need to switch those dates to the UK dd/mm/yyyy. Saving the file seems well and good. But when I reopen the file many of the dates appear without the zeros if they had one as the first digit. An example:
saved as - 03/03/2012
when re-opened - 3/3/2012
I'm using Excel 2007 and saved from xlsx to all possible CSV options (mac, windows, ms-dos..)
Anyone know why this is happening, or more importantly a solution?
For windows users, go to the control panel, pick regional and language options and pick the date format you want. In windows XP, the option for dd/mm/YYYY format only appears if you pick "English (United Kingdom)". I have not tried the export, but this fixed the import of a csv file.
i have problem with excel changing the date format so it fits regional settings.
my problem is:
i am creating tool in which user chose which *.csv file to import and work with. While tool is on user side i can't rely on regional setting - tool have to work for all.
Problem is that excel automatically change date format to fits regional setting and therefore it is wrong or i can't parse it with static delimiter (like '/').
I know the format in which the date is written in the csv file (yyyy-mm-dd or dd/mm/yy) and i would like to read that date as a text so i can use DateSerial to create correct date.
Is there any way to read csv only as text and prevent excel from changing it to date (based on user regional settings) automatically ?
Thank you.
When importing, specify the column as text.
Or, put an apostrophe at the start of each date value. This is the "this is a text value, don't reformat it" symbol.
example
123,'12/29/1999,blah blah