Read Client Files in Folder

jordi79
Member Posts: 280
Hi,
I have read the thread:
viewtopic.php?f=32&t=57342&start=0
and have managed to get it running on a 2 tier. But on a 3 tier, it seems that it cannot read the files.
My code is:
And the error message is:
Microsoft Dynamics NAV
A call to System.IO.Directory.GetFiles failed with this message: Could not find a part of the path 'c:\New'.
OK
The question is how do I upload the folder to the server?
I have read the thread:
viewtopic.php?f=32&t=57342&start=0
and have managed to get it running on a 2 tier. But on a 3 tier, it seems that it cannot read the files.
My code is:
Name DataType Subtype Length dn_Folder DotNet System.IO.Directory.'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' dn_Lst DotNet System.Collections.Generic.List`1.'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' dn_Obj DotNet System.Object.'mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' i Integer dn_Obj := dn_Folder.GetFiles(FORMAT('c:\New'), '*.*'); dn_Lst := dn_Lst.List; dn_Lst.AddRange(dn_Obj); IF dn_Lst.Count > 0 THEN BEGIN FOR i := 0 TO dn_Lst.Count - 1 DO BEGIN message(FORMAT(dn_Lst.Item(i))); END; END;
And the error message is:
Microsoft Dynamics NAV
A call to System.IO.Directory.GetFiles failed with this message: Could not find a part of the path 'c:\New'.
OK
The question is how do I upload the folder to the server?
0
Comments
-
Did you set RunOnClient=Yes on DotNet variables?0
-
Yup. You are correct. Silly mistake.0
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