LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

File Path "\\\\"

Hello,

 

I have a customer with a server that I am trying to save some files to.

 

The path is \\\\AST\home\public.

 

I am thinking the 4 \ is giving me problems.  I was doing some research and server paths usually start with just 2 \ (i.e. \\AST\home\public)

 

Any suggestions on how to handle this?  Do I just remove to 2 \ or is there a more elegant way?

 

Thanks

Dan Shangraw, P.E.


   

0 Kudos
Message 1 of 5
(172 Views)

@ASTDan wrote:

Hello,

 

I have a customer with a server that I am trying to save some files to.

 

The path is \\\\AST\home\public.

 

I am thinking the 4 \ is giving me problems.  I was doing some research and server paths usually start with just 2 \ (i.e. \\AST\home\public)

 

Any suggestions on how to handle this?  Do I just remove to 2 \ or is there a more elegant way?

 

Thanks


It is weird that it contains four "\", my search also resulted in "\\" only and not four. 

Santhosh
Soliton Technologies

New to the forum? Please read community guidelines and how to ask smart questions

Only two ways to appreciate someone who spent their free time to reply/answer your question - give them Kudos or mark their reply as the answer/solution.

Finding it hard to source NI hardware? Try NI Trading Post
0 Kudos
Message 2 of 5
(123 Views)

What is the OS of the server?

Is this a path datatype or a string?

If this is a plain string and is set to \-code display, "\\a\b\c" would show as "\\\\a\\b\\c", also duplicating the other ones. Not quite the same.

How are you communicating with the server? Is this just a network shared drive?

 

In what sense is it "giving you problems"? (error messages, etc.) What have you tried? What problems did you get when using only two at the beginning?

0 Kudos
Message 3 of 5
(106 Views)

Could it be that the other backslashes in that path are actually double and you missed that? In that case your customer simply copy-pasted the path from a C source or something else using \ escaping. A UNC server name does look like \\\\server\\share\\path in \ escaped form as used in C code.

 

LabVIEW strings or paths don’t use that unless you set the string explicitly into \~Code display mode.

 

There is another path prefix in Windows that is \\?\ or \\.\ which indicate to Windows to skip path length limitation for file respectively device paths but that is a very special kernel detail.

Rolf Kalbermatter
My Blog
0 Kudos
Message 4 of 5
(100 Views)

Found the problem.

 

Bug in my code.  I was adding \\ for some reason.  

 

Thanks all

Dan Shangraw, P.E.


   

Message 5 of 5
(52 Views)