LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Is there any way to list the shares on a server?

In Windows XP, I'm processing data stored on separate hard drives connected to a computer set up as a server. Each drive is listed individually under the server, i.e., \\server\drive1, \\server\drive2, .... Is there any easy way to get a list of these drives? The list directory function fails on \\server, and apparently stripping a \\server\share UNC path doesn't change the path. Also, I'm not sure if this is related, but since I started playing with this, LabVIEW has crashed 3 times.

 

Chris

0 Kudos
Message 1 of 3
(2,814 Views)

So, LabVIEW just crashed again. This is the error:

Fatal Internal Error : "fpsane.cpp", line 432

 

I don't know how this is connected to anything, but the error occurred when I closed a cmd window where the working directory was \\server\drive1.

 

I think I will restart now. 😞

Chris

0 Kudos
Message 2 of 3
(2,808 Views)

Hi,

 

Inside your VI, you can use the following functions of Windows API. You must create the NETRESOURCE Buffer before call the "mpr.dll"

 

WNetOpenEnum

WNetEnumResource

WNetCloseEnum

 

Message 3 of 3
(2,751 Views)