Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics NAV (Archived)

Dataport Import

(0) ShareShare
ReportReport
Posted on by 65

I created a dataport in Navision to import Engineering BOM lines from a text file. I wasn't able to successfully import the lines into Navision, and i wasn't getting any error messages at all. i pretty new to designing dataport. I would gladly appreciate your help.

Thanks

*This post is locked for comments

  • Suggested answer
    Suresh Kulla Profile Picture
    Suresh Kulla 43,745 on at
    RE: Dataport Import

    unfortunately you cannot sort based on the Variable value it should be a field, then you can create a key and sort the dataitem based on that field.

  • MowaH Profile Picture
    MowaH 65 on at
    RE: Dataport Import

    2009 Classic SP1

  • Suggested answer
    Suresh Kulla Profile Picture
    Suresh Kulla 43,745 on at
    RE: Dataport Import

    Are you using the classic version or RTC version ?

  • MowaH Profile Picture
    MowaH 65 on at
    RE: Dataport Import

    Great, it works as well. Thanks for the help Suresh, i am not a developer, but i have been thrown into this role. I do have another issue i need help with.

    The report in 2009 is called Order Pick Ticket report, and and the dataitem used is the sales line, there is a code in the back end that pull the information from the item specifically the shelf no, but for the life of me not sure how to use this information to create a sorting in the report.  

    IF Item.GET("Sales Line"."No.") THEN BEGIN

    ShelfNo := Item."Shelf No.";

  • Suggested answer
    Suresh Kulla Profile Picture
    Suresh Kulla 43,745 on at
    RE: Dataport Import

    You don't need to use Item.INIT statement and the IF condition to check for type::Item since you already have Item.GET statement. After Line No. Insert you just need this code

    IF Item.GET("No.") THEN

     "Description" := Item.Description;

    IF NOT INSERT THEN

    MODIFY;

  • MowaH Profile Picture
    MowaH 65 on at
    RE: Dataport Import

    Final-Code.png

    I was able to complete the dataport import process, this is my final code. 

    Thanks.

  • Verified answer
    Suresh Kulla Profile Picture
    Suresh Kulla 43,745 on at
    RE: Dataport Import

    In OnAfterImportRecord Trigger just add this code

    IF Item.GET("No.") THEN

      "Description" := Item.Description;

    IF NOT INSERT THEN

     MODIFY;

  • MowaH Profile Picture
    MowaH 65 on at
    RE: Dataport Import

    I took your advice, and added those columns but i am really not sure how to write the code to pull in the item description into the Engineering BOM line. I would appreciate your help.

  • Suggested answer
    Suresh Kulla Profile Picture
    Suresh Kulla 43,745 on at
    RE: Dataport Import

    In your dataport fields you only have No. and Quantity, how are you getting the BOM Number, if you include all the fields in the file & in the dataport fields then you don't need to add any code, the dataport will import it.  Include your BOM Number, Line Number and for Description you can add the code to retrieve it. Check the standard dataport like 5901.

  • MowaH Profile Picture
    MowaH 65 on at
    RE: Dataport Import

    EBOM-Review-2.pngEBOM-Review-2.png

    I was able review the codes and was able to import the data, but my issue now it to match Quantity to Quantity Per.

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 Verified Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,445 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans