Date Period Counter in CAL ?

Alex
Member Posts: 54
Hello World !
I have following problem, i what to filter
a record with the date filter. So fare so good.
In C/AL:
i use TODAY (command), and now i what the record filtered
by my business period.
eg.
if we have the 13.03.00 then first Periode = 01.03.00..31.03.00
if we have then 15.04.00 then Output P2 (secound Period)
...
and now Filter the Record like this
Setfilter(date,'%1',01.03.00..31.03.00) Periode one
anyone have an idea how to realize automate
this problem ???
Best regards
Alex Schubert
ERP & Navision
Dolphin Communication Technologies GmbH
Otto-Hahnstr. 1 c
D-69190 Walldorf
DolphinCT.de
I have following problem, i what to filter
a record with the date filter. So fare so good.
In C/AL:
i use TODAY (command), and now i what the record filtered
by my business period.
eg.
if we have the 13.03.00 then first Periode = 01.03.00..31.03.00
if we have then 15.04.00 then Output P2 (secound Period)
...
and now Filter the Record like this
Setfilter(date,'%1',01.03.00..31.03.00) Periode one
anyone have an idea how to realize automate
this problem ???
Best regards
Alex Schubert
ERP & Navision
Dolphin Communication Technologies GmbH
Otto-Hahnstr. 1 c
D-69190 Walldorf
DolphinCT.de
Best regards
Alex Schubert
ERP & Navision
Dolphin Communication Technologies GmbH
Otto-Hahnstr. 1 c
D-69190 Walldorf
Alex Schubert
ERP & Navision
Dolphin Communication Technologies GmbH
Otto-Hahnstr. 1 c
D-69190 Walldorf
0
Comments
-
To determine the period dates, access the Accounting Period table (50). TO get the current period:
// periods starting before today
AP.setrange("Start Date", 0D, TODAY);
AP.FIND('+'); // latest period
PeriodStart := AP."Start Date"; // start date
AP.setrange("Start Date"); // clear filter
AP.NEXT(1); // next period
// last period ended the day before the next period starts
EndDate := CALCDATE("-1D", AP."Start Date");
To get the next period's dates, repeat the last group of statements-jp0
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