Can't run custom RunBaseBatch-extended class

poverocane
Member Posts: 32
Hi all and thanks in advance for all your responses...
I've got a problem with a class i created extending system class RunBaseBatch.
I have included in it all necessary methods: run, runsImpersonated, pack, unpack with the right code (i think!)...
Class and its methods work perfectly when i run them directly, but when i schedule the execution, AX says me that the job have been correctly added to the job queue, it shows me the "Execution" and "Ended" states in the dedicated window, but nothing happened.
What can be the problem?
In addition, i can't start the debugger in batch mode, despite i've followed the right procedure to enable it...
Thanks a lot.
Poverocane.
I've got a problem with a class i created extending system class RunBaseBatch.
I have included in it all necessary methods: run, runsImpersonated, pack, unpack with the right code (i think!)...
Class and its methods work perfectly when i run them directly, but when i schedule the execution, AX says me that the job have been correctly added to the job queue, it shows me the "Execution" and "Ended" states in the dedicated window, but nothing happened.
What can be the problem?
In addition, i can't start the debugger in batch mode, despite i've followed the right procedure to enable it...
Thanks a lot.
Poverocane.
Fantasy is more important than knowledge.
A. Einstein
A. Einstein
0
Answers
-
The problem was in variable packing/unpacking process.
This process (override of pack and unpack methods of RunBaseBatch class) not only work to preserve packed variables' values between executions of the class, but also provide a way to "transfer" variable values between client and server tiers.
On client tier, I was not packing a variable value that i needed on server tier, so this value was ever blank. Once packed, the value is now available.
For the debugger: some methods can not start the debugger (those on client tier, i presume), but if i open the debugger after adding the breakpoint and before scheduling the job, it works correctly.
I hope this can help.
Poverocane.Fantasy is more important than knowledge.
A. Einstein0
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