code_junkie

How to create an X++ batch job in Axapta 3.0?

Nov 11th, 2011
147
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.53 KB | None | 0 0
  1. static void ExternalDataRead(Args _args)
  2. {
  3. ...
  4. }
  5.  
  6. class MyBatchJob extends RunBaseBatch
  7. {
  8. }
  9.  
  10. public container pack()
  11. {
  12. return connull();
  13. }
  14.  
  15. public boolean unpack(container packedClass)
  16. {
  17. return true;
  18. }
  19.  
  20. public void run()
  21. {
  22. ;
  23. ...
  24. info("MyBatchJob completed");
  25. }
  26.  
  27. static void main(Args _args)
  28. {
  29. MyBatchJob myBatchJob = new MyBatchJob();
  30. ;
  31. if(myBatchJob.prompt())
  32. {
  33. myBatchJob.run();
  34. }
  35. }
  36.  
  37. server client static public ClassDescription description()
  38. {
  39. return "My batch job";
  40. }
Add Comment
Please, Sign In to add comment