SOLVED: Using File Silent File Upload with Webservice
AlexRichter
Member Posts: 4
Dear community,
we are working on a Load Test Solution for our System (NAV 2015).
One of our Scenarios requires File Upload.
As we figured out already File uploading is not supported by Loadt Test Suite, so we come around with the following Workaround:
We created a Webservice which will invoke the File Upload.
The Websersice Function calls a SetParameter function in the Report which is doing the Excel File Import and sets all necessary Parameters including SilentFileUpload.
If i call the Webservice Function directly from Client it works as expected but the same call via Webservice stops with the follwoing Error in Visual Studio:
I identified the ClientFileHelpder Variable in CU 419 as the Error source as its set to run on Client.

I could copy the Function and change the Setting but im quite Sure that this will not help as it fill try to upload the temporary file vom server to NAV later on again where i will be having the same issue.
Where you facing the same issue already and having a solution for a scenario like this or some ideas how to solve this issue?
Thanks for your input,
Alex
For those who are on TechDays - Enjoy it
we are working on a Load Test Solution for our System (NAV 2015).
One of our Scenarios requires File Upload.
As we figured out already File uploading is not supported by Loadt Test Suite, so we come around with the following Workaround:
We created a Webservice which will invoke the File Upload.
The Websersice Function calls a SetParameter function in the Report which is doing the Excel File Import and sets all necessary Parameters including SilentFileUpload.
If i call the Webservice Function directly from Client it works as expected but the same call via Webservice stops with the follwoing Error in Visual Studio:
Additional information:
Microsoft Dynamics NAV Business Web Services attempted to issue a client callback to create a DotNet object:
System.IO.File (CodeUnit 419 File Management).
Client callbacks are not supported on Microsoft Dynamics NAV Business Web Services.
I identified the ClientFileHelpder Variable in CU 419 as the Error source as its set to run on Client.

I could copy the Function and change the Setting but im quite Sure that this will not help as it fill try to upload the temporary file vom server to NAV later on again where i will be having the same issue.
Where you facing the same issue already and having a solution for a scenario like this or some ideas how to solve this issue?
Thanks for your input,
Alex
For those who are on TechDays - Enjoy it
0
Answers
-
Your webservice is running on the server, so you don't have to upload the file you can just move it. You need to go around the SilentFileUplaod with GUIAllowed and just move/copy the file to a "ServerFileName"
/Juha0 -
Hey Juha,
you are right, if i bypass the whole File Managment then it works.
Actually quite an easy straught forward solution.
Thank you
Alex
0 -
hey Juha,
Could you please share me you Solution. I tried a million times and it always a failure.
Thank you.
Syed..0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.7K 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
- 326 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