- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
The NLS_LI Parameter List in the Intel FORTRAN Developer Guide includes settings I need for customized date, time and number formats. How do I invoke these in code or in Project Properties? Thx.
Ссылка скопирована
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
I found this link:
Hope that's helpful.
Having worked across several locales with data files which could have been created with different formats, I found that it was important to be able to determine which locate the data file had been created in, rather than assuming that the current locale was correct. This got tricky when my app created data files which users could open as a CSV file in Excel, so getting the dividers and the decimal points correct was critical.
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Thanks, David. The next challenge is to discover which of the 100+ countries has the format I need. But even this will not help if IFORT does not act on them automatically. For instance, if the locale says "no leading zeros", but IFORT always does leading zeros, then I'll have to code a work-around.
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Hi Mike,
My understanding is that you can format numbers, time and date using functions from the IFNLS library
See the examples at https://www.intel.com/content/www/us/en/docs/fortran-compiler/developer-guide-reference/2023-1/nls-and-mcbs-routines-on-windows.html
My code was simpler, since I only needed to know the decimal point and separator characters.
Hope that points you in the right direction.
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
Thanks for the link, David. It confirms what I suspected.
NLS is too awkward, so have written my own formatting routines.
- Отметить как новое
- Закладка
- Подписаться
- Отключить
- Подписка на RSS-канал
- Выделить
- Печать
- Сообщить о недопустимом содержимом
I looked at NLS back in 2014 and gave up and did things a different way.... https://community.intel.com/t5/Intel-Fortran-Compiler/National-Language-Support-NLS-Usage-in-Ifort/m-p/953297#M92744%3Fwapkw=nls

- Подписка на RSS-канал
- Отметить тему как новую
- Отметить тему как прочитанную
- Выполнить отслеживание данной Тема для текущего пользователя
- Закладка
- Подписаться
- Страница в формате печати