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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Unanswered

'Number selection is canceled.' when assigning a number from a number sequence

(0) ShareShare
ReportReport
Posted on by 105

i use visual studio to create budget header using X++ in D365FO

i face this issue

Microsoft.Dynamics.Ax.Xpp.ErrorException: 'Number selection is canceled.'

in this line of number sequence

 numberSeq = NumberSeq::newGetNum(BudgetParameters::numRefBudgetTransactionId());

info(numberSeq.num()); ---- in this line 

and i'm sure there is a number sequence in the module parameter .. any help ?

I have the same question (0)
  • Martin Dráb Profile Picture
    237,880 Most Valuable Professional on at

    Can you please debug the code and tell us where exactly does the error gets thrown?

  • Gunjan Bhattachayya Profile Picture
    35,423 on at

    Hi Omar,

    Did you check if the number sequence is set up properly? Are you able to create Budget entries from the UI

  • Omar Abdelhamed Dev Profile Picture
    105 on at

    my required is create it using X++

    and number sequences is setup and i have many transactions using the number seq throw UI but when i use

    numberSeq.num() method i got the mentioned error

  • Martin Dráb Profile Picture
    237,880 Most Valuable Professional on at

    numberSeq.num() isn't the line that throws the error. It just calls a method (num()), which calls another method (runNumber()), which calls more methods... and somewhere a 'throw' statement is used to actually throw the exception.

    You need to look at place where the error is thrown to understand why it happens.

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 611 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 529 Super User 2025 Season 2

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 285 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans