Posting No. Series for Imported Journal Lines
mikelacey
Member Posts: 15
Hello,
I have a dataport set up to import journal lines into a general journal batch from a MS Excel csv file. The dataport contains the following lines of code at the On Before Import Record stage:
docNo:='IM001';
VALIDATE("Document No.", docNo);
"docNo" is set up as a variable. I have this beacuse Navision requires something to be entered in the Document No. field for a journal to post. The journal batch that the lines are imported into is set up with a posting no. series. However once the journal lines have been posted (after the dataport has been run)....the posted lines still have the 'IM001' as the document number and have not been replaced with the posting number series set up in the journal batch as expected.
Can anyone help me please? If I manually type a journal line into this batch it uses the number series set up as the posting no. series for the batch when I post.
I am running Navision GB v4.0 on C/Side.
Thanks,
Mike
I have a dataport set up to import journal lines into a general journal batch from a MS Excel csv file. The dataport contains the following lines of code at the On Before Import Record stage:
docNo:='IM001';
VALIDATE("Document No.", docNo);
"docNo" is set up as a variable. I have this beacuse Navision requires something to be entered in the Document No. field for a journal to post. The journal batch that the lines are imported into is set up with a posting no. series. However once the journal lines have been posted (after the dataport has been run)....the posted lines still have the 'IM001' as the document number and have not been replaced with the posting number series set up in the journal batch as expected.
Can anyone help me please? If I manually type a journal line into this batch it uses the number series set up as the posting no. series for the batch when I post.
I am running Navision GB v4.0 on C/Side.
Thanks,
Mike
0
Comments
-
Hello Mike,
You can always use the NoSeriesManagement codeunit and use the GetNextNo routine when ever you want to get the next number from a number series to put in your journal lines...
When you manually enter a journal line, then Nav uses alot of code to initialize the record and build up information, like the Document No.
You don't need to use the default code that builds the doc no when entering the journal line manually if your only problem is the document no...
Sample of GetNextNo usage:
http://www.mibuso.com/forum/viewtopic.p ... =getnextno
http://www.mibuso.com/forum/viewtopic.p ... =getnextno
http://www.mibuso.com/forum/viewtopic.p ... =getnextno
You get the first document no at the start of the dataport and then increase it manually when you want to change the article...0
Categories
- All Categories
- 75 General
- 75 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 610 NAV Courses, Exams & Certification
- 1.9K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 251 Dynamics CRM
- 103 Dynamics GP
- 6 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 28 Design Patterns (General & Best Practices)
- Architectural Patterns
- 9 Design Patterns
- 4 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1K General Chat
- 1.6K Website
- 77 Testing
- 1.2K Download section
- 23 How Tos section
- 249 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions
