Create Dir UNC (OCX)

Administrator
Member, Moderator, Administrator Posts: 2,506
Create Dir UNC (OCX)
May be you'll have to create a folder on a Shared folder, but with the LAutFileSystemObject you can't. So Register this ocx, and write the followinfg function in a codeunit and use it like this
CreateSubDirUNC(''\\computer\share\2000\10');
\\computer\share\2000\ must exist or use before
CreateSubDirUNC(''\\computer\share\2000');
Function to paste in a codeunit: with variable
Name DataType Subtype Length
CreateFold OCX MyCreateFolderOCX Control
CreateSubDirUNC(ItxtSubdir : Text[1024])
CLEAR(CreateFold);
CreateFold.CreateFolder(ItxtSubdir);
http://www.mibuso.com/dlinfo.asp?FileID=939
Discuss this download here.
May be you'll have to create a folder on a Shared folder, but with the LAutFileSystemObject you can't. So Register this ocx, and write the followinfg function in a codeunit and use it like this
CreateSubDirUNC(''\\computer\share\2000\10');
\\computer\share\2000\ must exist or use before
CreateSubDirUNC(''\\computer\share\2000');
Function to paste in a codeunit: with variable
Name DataType Subtype Length
CreateFold OCX MyCreateFolderOCX Control
CreateSubDirUNC(ItxtSubdir : Text[1024])
CLEAR(CreateFold);
CreateFold.CreateFolder(ItxtSubdir);
http://www.mibuso.com/dlinfo.asp?FileID=939
Discuss this download here.
0
Comments
-
it is not necesarry to use an ocx object to achieve this.
i think you can use the shell command like this somehow:Shell('md "\\computername\share\2000\10');
though i'm not totally sure.
if you think the security messages are anoying use the automation variable 'Windows Script Host Object Model'.WshShell (lclsShell) and the 'run' method of this object.CREATE(lclsShell); lclsShell.Run('md "\\computername\share\2000\10', 1, 3); CLEAR(lclsShell);
These methods do not require you to distribute an OCX file to client computers.In a world without Borders or Fences, who needs Windows and Gates?0 -
janpieter wrote:variable 'Windows Script Host Object Model'.WshShell (lclsShell) and the 'run' method of this object.
CREATE(lclsShell); lclsShell.Run('md "\\computername\share\2000\10', 1, 3); CLEAR(lclsShell);
Regards,Alain Krikilion
No PM,please use the forum. || May the <SOLVED>-attribute be in your title!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