Automatic Multiple Export

KPLewisBPM
Member Posts: 12
I have 4 dataports I am running that exports to CSV. Is it possible to creat a form with a button which will automatically run all 4 dataports with the specified file output name and location.
Kind Regards
Kind Regards
0
Comments
-
Sure.
In the properties for the dataport you change
Import to No
FileName to the exact filename
On the cammandbutton you add the code
DATAPORT.RUN(DATAPORT::"Dataport # 1",FALSE);
DATAPORT.RUN(DATAPORT::"Dataport # 2",FALSE);
etc.0 -
Thanks Torben R.
Works fine... When I run it asks if I want to overwrite the CSV file that already exists (4 times), Can I get it to ignore this msg and overwrite all 4 csv's automatically?
Kind Regards0 -
KPLewisBPM wrote:Thanks Torben R.
Works fine... When I run it asks if I want to overwrite the CSV file that already exists (4 times), Can I get it to ignore this msg and overwrite all 4 csv's automatically?
Kind Regards
Within the AL code of the dataport within the "Dataport - OnInitDataport()" event add this command:
CurrFile.QUERYREPLACE(FALSE);
This will make the dataport not prompt for file replacement.0 -
Everything is now working according to my outlined specification.
Thanks for your help Guy's
Kind Regards
K Lewis0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K 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
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions