Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics NAV (Archived)

Job No and Sales Orders - easy question

Posted on by Microsoft Employee

Question, how would I make NAV create a new Job No. (e.g. SOJOB10001) each time a new Sales Order (e.g. SO10001) is made? Is this implemented using Job Queues?

Background:

We are a small business that is in over our heads with a new NAV purchase. Our partner has classified us as a Job Manufacturing company and is recommending that we implement Jobs and Assembly Orders. We are demonstrating what we have implemented on our own to our partner next week. 70% of our business in manufacturing of unique industrial equipment, the remaining 30% is consulting/project type jobs. We think that we want to implement our business processes by using the Sales Quote, Sales Orders, and Sales Invoice functionality while in parallel creating a Job for each Sales Order to record actual labor (unbillable labor, Engineering, tech support, and Production/Assembly). In order to do this we have to be able to know what Job records correspond to what Sales Orders. We are aware of Job Manager add-on but are trying to implement within the out of the box NAV.

*This post is locked for comments

  • Verified answer
    RE: Job No and Sales Orders - easy question

    Hi,

    This is a customization, hence you are expected to obtain a developer license.

    Hope it helps.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Job No and Sales Orders - easy question

    Is a developer license required to implement your suggestion?

    Is there a way to do this without a developer license?

  • Verified answer
    RE: Job No and Sales Orders - easy question

    Hi,

    "We do not want any interaction between jobs and sales orders, we just want the numbers to be synchronized (and perhaps a few fields such as the customer information to be copied to the job). I suppose we can do this all manually." --> This part can be automated, either writing a codeunit/report/ writing in suitable table triggers (OnInsert() / OnModify()) to create a job whenever there is a new sales order is created.

    "Can this be done within NAV using Job Queue?" --> Probably. But you can write the automation code in the created codeunit/report/table trigger. The job queue is best for scheduling. Since this is not a scheduling task, not necessary. 

    "We notice that there is a Copy Job C/AL (www.navutils.com/.../1006_code.html)" --> The code says that you can copy either from Job Planning Lines or Job Ledger Entry. You can design a similar pattern to copy from Sales Order to Job.

    To answer your question, I construct the following code on my OnModify() Trigger on the Sales Header(36) Table. Please note that this is just a skeleton, not the final implementation.

    OnModify()
    
    IF "Document Type" = "Document Type"::Order THEN
    BEGIN
      Job.SETRANGE(Job."Sales Order Reference", "No."); //Insert the Sales Order No. as reference
      IF NOT Job.FIND('-') THEN
      BEGIN
        Job."Bill-to Customer No." := "Bill-to Customer No.";
        // More fields to synchronize
        // ...
        // ..
        // .
        Job.INSERT(TRUE);
      END
      ELSE
      BEGIN
        Job."Bill-to Customer No." := "Bill-to Customer No.";
        // More fields to synchronize
        // ...
        // ..
        // .
        Job.MODIFY(TRUE);
      END;
    END;


    Hope it helps.

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Job No and Sales Orders - easy question

    We do not want any interaction between jobs and sales orders, we just want the numbers to be synchronized (and perhaps a few fields such as the customer information to be copied to the job). I suppose we can do this all manually.

    While an explicit how-to response to my question would be very helpful, we do have IT talent in-house. If someone could provide a high level suggestion then we can do our own research to fill in the details.

    For example,

    Can this be done within NAV using Job Queue? We notice that there is a Copy Job C/AL (www.navutils.com/.../1006_code.html), what we do not know is how to implement it with input from a released Sales Order.

  • RE: Job No and Sales Orders - easy question

    Hi,

    Your requirement leads towards a customization.

    I am not sure how your Sales Order (Header and Lines) interacts with the corresponding Job that you automatically create. All the scenarios must be analysed before the customization.

    Job queues in Microsoft Dynamics NAV enable you to specify, request, and control when certain processes are run, such as the processing of a report or executing a codeunit.

    Feasiblility must be checked how a Job Queue can be helpful to fulfill your requirement.

    Read more: msdn.microsoft.com/.../hh879489(v=nav.90).aspx

    Hope it helps.

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,214 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans