Report 795 Adjust Cost - Item Entries on Job Sch

gadzilla1
Member Posts: 316
Hello,
I'm running 4 SP3 and need to use the job scheduler to run Report 795 Adjust Cost - Item Entries with today's date.
I've worked out the job scheduler setup (for the time of day to run), but was wondering...is there a way to 'run' the report as is, and enter/validate today's date on the job scheduler, OR
do I set up a processing only report with the same code as found in Report 795?
Thanks, Chris
I'm running 4 SP3 and need to use the job scheduler to run Report 795 Adjust Cost - Item Entries with today's date.
I've worked out the job scheduler setup (for the time of day to run), but was wondering...is there a way to 'run' the report as is, and enter/validate today's date on the job scheduler, OR
do I set up a processing only report with the same code as found in Report 795?
Thanks, Chris
0
Answers
-
1) Some modifications are needed like add conditions to not open dialog box with progress when the process is running (NAS cannot display the dialog...) - it means adding "IF GUIALLOWED then" before each call of some function with Dialog variable.
2) You can add some funtionality to set the parameters of the report through parameters of the JobQueue0 -
Thank you for the reply.
What I was thinking, is that I create a custom processing only report copied 100% from Report 795. I set Job Scheduler to run the report 1x daily at 10pm. The only part of the code that I'll change will be automatically setting the posting date to TODAY. Please check out the following:
//IF PostingDate = 0D THEN
// ERROR(Text004);
//SET POSTING DATE
PostingDate = TODAY;
ItemApplnEntry.LOCKTABLE;
IF NOT ItemApplnEntry.FIND('+') THEN
EXIT;
ItemLedgEntry.LOCKTABLE;
IF NOT ItemLedgEntry.FIND('+') THEN
EXIT;
AvgCostAdjmtEntryPoint.LOCKTABLE;
IF AvgCostAdjmtEntryPoint.FIND('+') THEN;
ValueEntry.LOCKTABLE;
IF NOT ValueEntry.FIND('+') THEN
EXIT;
InvtAdjmt.SetProperties(PostingDate,FALSE);
InvtAdjmt.MakeMultiLevelAdjmt;
UpdateItemAnalysisView.UpdateAll(0,TRUE);0 -
Better is to create new report, which will take parameters from outside (if you need) and will call the standard report which will have only additional function to set the startup parmeters through code. In this case you will not have doubled the application logic, it will be easier for maintenance, it is more clear etc.etc.
In your way, if there will be some bug or change in the standard object, you need to no forget to apply the change to another report too, pepople which will do not know about this, will have problems too etc...0 -
Hi Kamil,
You're right, I tried to do what I proposed and was unsuccesful do the 'you do not have permission to insert into the item ledger entries' error. Are you aware of any examples of a processing report that runs another report? If not no problem.
Thanks - Chris0 -
-
gadzilla1 wrote:Hi Kamil,
You're right, I tried to do what I proposed and was unsuccesful do the 'you do not have permission to insert into the item ledger entries' error. Are you aware of any examples of a processing report that runs another report? If not no problem.
Thanks - Chris
Of course, you need to have appropriate license to be able to modify the report. It means, you need to ask your Partner to do that, because you alone cannot make the conditions to not open progress dialog etc.0 -
Thank you very much to all...the last two posts (and link) helped my understanding a great deal. I will put as solved, and ask my partner for assistance.
Chris0
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