cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted

Copy and Paste of Directory

Siemens Experimenter Siemens Experimenter
Siemens Experimenter

Hi Sir/Madam,

 

I am searching for copy directory structures from one location to another using NXOpen APIs.

I found RemoteUtilities::copyFile() function but it just copies file. Can anyone please tell me how to get handle to directory or traverse through Director? Is there NXOpen API present for this or not?

 

3 REPLIES

Re: Copy and Paste of Directory

Esteemed Contributor
Esteemed Contributor

There is no NXOpen call, since regular file system handling is supported by the development language you use. Search the web for examples of the task written in your development language.

NXOpen is only an extension covering the NX specific environment, regular environments are subject to the development language.

Stefan Pendl, Systemmanager CAx, HAIDLMAIR GmbH
Production: NX10.0.3, VERICUT 8.0, FBM, MRL 3.1.4 | TcUA 10.1 MP7 Patch 0 (10.1.7.0) | TcVis 10.1
Development: VB.NET, Tcl/Tk    Testing: NX11.0 EAP, NX12.0 EAP

How to Get the Most from Your Signature in the Community

Re: Copy and Paste of Directory

Siemens Experimenter Siemens Experimenter
Siemens Experimenter
Thanks Smiley Happy

Re: Copy and Paste of Directory

Siemens Phenom Siemens Phenom
Siemens Phenom

There were (and are) GRIP commands for doing this sort of thing. I suppose that's one reason people expect to find analogous NX/Open functions. But, there aren't any, because the .NET framework provides them, instead.

 

To help people migrating from GRIP, there is some discussion of .NET functions for handling files and directories in the "SNAP and NX/Open for GRIP Enthusiasts" document (which is included in the standard NX docs). See section 24 of that document.

 

As that document tells you, the relevant .NET functions can be found in the System.IO.File, System.IO.Directory, System.IO.FileInfo and System.IO.DirectoryInfo classes. 

 

山田
yamada