NAV date field data with three characters month (31-Dec-14)

smmurugan
Member Posts: 33
Hi Friends,
Is it possible in NAV to enter data in date field as '11-Dec-14' format?
To avoid confusion among users about date format - 'dd-mm-yy' or 'mm-dd-yy' - is it possible in NAV enter date as 11-Dec-14?
I tried both in Classic as well RTC - not accepting.
Can anyone confirm this how NAV works?
Thanks
Murugan
Is it possible in NAV to enter data in date field as '11-Dec-14' format?
To avoid confusion among users about date format - 'dd-mm-yy' or 'mm-dd-yy' - is it possible in NAV enter date as 11-Dec-14?
I tried both in Classic as well RTC - not accepting.
Can anyone confirm this how NAV works?
Thanks
Murugan
0
Comments
-
Date format in NAV depends on Windows Regional settings. Please change the Date Format in Regional settings of machine and try.0
-
I cannot confirm if you can't use months as text. Don't think you can.
But you could use the calender in RTC of course.
Or use day of the week plus weeknumber. Like m12 for mondag week 12.
Tino Ruijs
Microsoft Dynamics NAV specialist0 -
Dear Mohana,
Thanks for the quick response.
Yes. That was the first thing I did. Please see the screenshot attached.
My Windows system date - 18-Dec-14
NAV Status bar date - 18-12-13
See the error below when I entered '11-Dec-14' in date field.
Microsoft Dynamics NAV Classic
'11-Dec-14' is not a valid date.
OK
0 -
Hi Tino,
I know these alternatives. But for the data entry users prefers to use this format to avoid any confusion.
Murugan0 -
-
alternative:
you'll need following code in function MakeDateText in codeunit 1 to convert your given date (e.g. 15-MAR-11) into a valid date value:
MakeDateText(VAR DateText : Text[250]) : Integer
// additional local variables
// mPos | Integer
// monthText | Text | 10
// monthValue | Integer
// Text Constant: Text022 | JAN,FEB,MAR,APR,MAY,JUN,JUL,AUG,SEP,OCT,NOV,DEC
Position := 1;
Length := STRLEN(DateText);
ReadCharacter(' ',DateText,Position,Length);
// begin changes
DateText := CONVERTSTR(DateText,'-',',');
monthText := SELECTSTR(2,DateText);
mPos := STRPOS(Text022,monthText);
IF mPos > 0 THEN BEGIN
monthValue := (mPos + 3) / 4;
monthText := PADSTR('',2 - STRLEN(FORMAT(monthValue)),'0') + FORMAT(monthValue);
DateText := SELECTSTR(1,DateText) + '-' + monthText + '-' + SELECTSTR(3,DateText);
END ELSE
DateText := CONVERTSTR(DateText,',','-');
// end changes
IF NOT FindText(PartOfText,DateText,Position,Length) THEN
...
cheersregards0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions