Skip to main content

Notifications

Finance | Project Operations, Human Resources, ...
Answered

How to run a batch class?

Posted on by 721
Hi,
I have a class created that takes 30-40min run. The class will be run by the user, by selecting menuitem. I have a problem to run this class as a batch. When trying to run, the following error appears.
 
//
I can't find what the cause of this error is.
 
Thanks.
 
  • Suggested answer
    Waed Ayyad Profile Picture
    Waed Ayyad 5,955 Super User 2024 Season 2 on at
    How to run a batch class?
     
    Can you verify the answer that help you in order for others in the future to get answers for their questions?
     
     
     
    Regards,
    Waed Ayyad
  • Hana Xue Profile Picture
    Hana Xue Microsoft Employee on at
    How to run a batch class?
    Hi,
    Thanks for your reply and sharing, if your problem is solved, you can mark this question as verified, which will help more people on the forum.
    Best Regards,
    Hana
     
  • Verified answer
    Shooowtek Profile Picture
    Shooowtek 721 on at
    How to run a batch class?
    Problem solved. Batch Management Service was disabled
  • Shooowtek Profile Picture
    Shooowtek 721 on at
    How to run a batch class?
    Hello,
     
    I fixed the problem and am now creating a batch job. But unfortunately I don't know how to start the execution, because the job is added to the queue, but all the time it has the status "Waiting".
    Does anyone perhaps know why this is happening?
  • Suggested answer
    Waed Ayyad Profile Picture
    Waed Ayyad 5,955 Super User 2024 Season 2 on at
    How to run a batch class?
    Hi @ Shooowtek,
     
    If you want the steps to run your class as batch, you can check the following link:
     
    but it seems you have an issue, when you run your code (class), Can you share your code? So, we can help you.
     
     
    Regards,
    Waed Ayyad  
  • Layan Jwei Profile Picture
    Layan Jwei 7,204 Super User 2024 Season 2 on at
    How to run a batch class?
    Hi Shooowtek,

    you didn't explain what you did exactly and you didn't show us ur code.
    Did you click batch processing as true, then clicked ok to run it?

    Also please debug and show us what line exactly it fails on

    Thanks,
    Layan Jweihan

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

November Spotlight Star - Khushbu Rajvi

Congratulations to a top community star!

Forum Structure Changes Coming on 11/8!

In our never-ending quest to help the Dynamics 365 Community members get answers faster …

Dynamics 365 Community Platform update – Oct 28

Welcome to the next edition of the Community Platform Update. This is a status …

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 290,900 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 229,275 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans