Options

Make a dataport write on different lines

A_RuffA_Ruff Member Posts: 6
edited 2015-09-11 in Navision Financials
Hello, mibuso community.

I'm sorry in advance if my English seems approximative.

So I'm working on a way for my company to edit "expedition files" that allow the company making the delivery to get information about them.

The structure of one of those files looks like this :

Expedition header
Details for expedition #1
Package 1
Package 2
...
Package N
Details for expedition #2
Package 1
...

And so on.

So I've been searching for a way to be able to write a dataport that would generate a file with this structure, but I can't seem to find a way to write on different lines : on each try, it first displayed all the lines "Details for expedition", then all the lines "Package". I'm using Navision Financials 2.60.A (french version)

If you could help me, I would be very thankful !

Comments

  • Options
    evandeveerdonkevandeveerdonk Member Posts: 49
    Hi A_Ruff,

    the best of doing this, is to create a textfile using commands like
    File.CREATE
    File.WRITE
    File.Close

    In that case, you are flexible.

    Ernst
    http://www.vssolutions NAV-Outlook synchronisation re-invented.
  • Options
    A_RuffA_Ruff Member Posts: 6
    Thanks Ernst!
    As I'm only an intern, I don't have Navision at home, so I'll try this tomorrow and I'll keep you posted!
  • Options
    A_RuffA_Ruff Member Posts: 6
    Hi again !

    So, I tried using a File.OPEN to modify the file, but it still dosn't work : the file outputted by the dataport is inaccessible.
    Moreover, after trying to output it in a different file, I had only one barcode. I can't seem to understand how to create a loop that would check the detail of my table "Expedition" to generate a different bar code for each item in the expedition.
  • Options
    apertierraapertierra Member Posts: 61
    You can simply create a report that exports to a text file and use it instead of a dataport.
    With the report you will be able to index areas so you can have the "header" and "detail" for each record and for each record of the detail use a different (or even multiple, since you will control the code) lines if you want to.
Sign In or Register to comment.