Importing serial Numbers

taher.bhataher.bha Member Posts: 48
Hi all,
Am trying to import an initial warehouse for a customer.
I am using a dataport so as to fill the Item Journal. But i cannot figure out How to import Item tracking lines (Serial Numbers).
The code in the 'Item Tracking Lines' Form (Id 6510) seems to be really Complex.
As a workaround I tried calling the form and adding the 'Tracking Specification' record loded by the dataport using a Function I created.
The problem that am facing is that when running the dataport on the serial numbers file, i cannot Run then Close Form 6510 on the OnAfterImportRecord() call, the dataport seems to keep all the forms open although CLEAR(frm6510) is called and then cause an error because data has been changed.

Hope I was clear enough. Any solutions/Ideas ?
Thx in advance.

Answers

  • Revolution1210Revolution1210 Member Posts: 161
    All lot/serial tracking prior to posting is stored in the Reservation Entry table (337).

    The way NAV handles this table is quite complex, so you need to make sure that you fully test any solutions, but don't be too scared :D it's not that bad...

    This is the best way to achieve what you want.

    1. Manually track a journal line as you would do if you were an end user filling in the journal.

    2. Open the reservation entry table and look at the entries which have been created as a result.

    3. Write code (in your Dataport) which populate the reservation entry table in the same manner as the system does.

    You don't need to populate all fields, but it should become apparent when you look at the entries the system generates, which ones you need to populate.

    Trial and error should get you there. Good luck :D

    ..also take a decision on the time you would spend writing code to do this, against the time it would take to have a user manually enter the journal. If there's not masses and masses of data, you may be better allowing the end user to take charge of the data entry themselves.
    Ian

    www.NextEqualZero.com
    A technical eye on Dynamics NAV
  • matttraxmatttrax Member Posts: 2,309
    Search should help you out. I have asked and answered questions on this topic.
  • ara3nara3n Member Posts: 9,256
    taher.bha wrote:
    Hi all,
    Am trying to import an initial warehouse for a customer.
    I am using a dataport so as to fill the Item Journal. But i cannot figure out How to import Item tracking lines (Serial Numbers).
    The code in the 'Item Tracking Lines' Form (Id 6510) seems to be really Complex.
    As a workaround I tried calling the form and adding the 'Tracking Specification' record loded by the dataport using a Function I created.
    The problem that am facing is that when running the dataport on the serial numbers file, i cannot Run then Close Form 6510 on the OnAfterImportRecord() call, the dataport seems to keep all the forms open although CLEAR(frm6510) is called and then cause an error because data has been changed.

    Hope I was clear enough. Any solutions/Ideas ?
    Thx in advance.

    If you are using warehouse management with directed pick and putaway, you need to import into warehouse journal. One line for serial/lot.
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
  • ara3nara3n Member Posts: 9,256
    Also take a look at this thread on how to populate the reservation using Navision Codeunits.

    http://www.mibuso.com/forum/viewtopic.p ... light=tada
    Ahmed Rashed Amini
    Independent Consultant/Developer


    blog: https://dynamicsuser.net/nav/b/ara3n
  • taher.bhataher.bha Member Posts: 48
    Thank you all for your help. The two following links helped me resolve my issue.

    http://www.mibuso.com/forum/viewtopic.p ... light=tada
    http://www.mibuso.com/forum/viewtopic.p ... ght=serial

    That wasn't as difficult as i expected it to be :)

    Thx again.
Sign In or Register to comment.