web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)
Answered

How to force Batch mode executing in any case for Batch class?

(0) ShareShare
ReportReport
Posted on by 110

I need to force in any case the Batch mode processing for my custom class extends RunBaseBatch by code. The user can't change the execution mode.

The shedule mode must only to be in Batch.
It's possible?

ForceBatchMode.jpg

I try to use in main method, before promt command these code line:

className.mustGoBatch();
className.parmInBatch(true);
className.doBatch();

BUT not work, I see the flag Batch processing switch off.

Thanks

*This post is locked for comments

  • Suggested answer
    JII SAADUDDIN Profile Picture
    1,832 on at

    I think it is doing part of exploiting the AX.. In my observation cannot be but you can able to customize runbatch. would?

  • Verified answer
    Martin Dráb Profile Picture
    241,353 Most Valuable Professional on at

    You can use className.batchInfo().parmBatchExecute(true) to change the value, but if users shouldn't be able to change it, you probably shouldn't be showing it at all.

  • Suggested answer
    Mea_ Profile Picture
    60,286 on at

    Hi DanielePax,

    Try to add to a dialog() method next code:

    this.batchInfo().parmBatchExecute(NoYes::Yes);

    or it could be done in main() as well

    className.batchInfo().parmBatchExecute(NoYes::Yes);
    
  • MC08 Profile Picture
    170 on at

    I meet same problem today and Martin and ievgen's answer get me out the the rid

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the August Top 10 Community Leaders

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans