🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: aus.computers.java
4 messages
4 total messages Started by Gary Perkins Tue, 08 Aug 2000 00:00
File Copy from UNC path
#513
Author: Gary Perkins
Date: Tue, 08 Aug 2000 00:00
8 lines
858 bytes
Hi,

Have a java application in a Windows NT environment and want ot use the File
object as such;

File inputFile = new File("\\server\share\filename.txt");

This does not work but works if I use a mapped drive letter?  Any ideas?
Re: File Copy from UNC path
#514
Author: Benjamin Johnston
Date: Wed, 09 Aug 2000 00:00
14 lines
1104 bytes
> Have a java application in a Windows NT environment and want ot use the File
> object as such;
> 
> File inputFile = new File("\\server\share\filename.txt");
> 
> This does not work but works if I use a mapped drive letter?  Any ideas?

Maybe you need to escape those slashes;
File inputFile = new File("\\\\server\\share\\filename.txt");

But otherwise, no idea.

-Benjamin Johnston
s355171@student.uq.edu.au
Re: File Copy from UNC path
#515
Author: Gary Perkins
Date: Wed, 09 Aug 2000 00:00
27 lines
1547 bytes
Yeah did that but no good.

Thanks anyway, I think it might ne a Windows NT permission thing (even
though I have set the share permissions correctly) but can copy the file by
UNC path in a command prompt.

Thanks anyway


Benjamin Johnston <s355171@student.uq.edu.au> wrote in message
news:Pine.OSF.4.21.0008090735410.24376-100000@student.uq.edu.au...
> > Have a java application in a Windows NT environment and want ot use the
File
> > object as such;
> >
> > File inputFile = new File("\\server\share\filename.txt");
> >
> > This does not work but works if I use a mapped drive letter?  Any ideas?
>
> Maybe you need to escape those slashes;
> File inputFile = new File("\\\\server\\share\\filename.txt");
>
> But otherwise, no idea.
>
> -Benjamin Johnston
> s355171@student.uq.edu.au
>
Re: File Copy from UNC path - FIXED
#516
Author: Gary Perkins
Date: Wed, 09 Aug 2000 00:00
39 lines
1789 bytes
Works fine under 1.2.2

Thanks


Gary Perkins <garyp@bgm.com.au> wrote in message
news:Rj1k5.79651$N4.2006183@ozemail.com.au...
> Yeah did that but no good.
>
> Thanks anyway, I think it might ne a Windows NT permission thing (even
> though I have set the share permissions correctly) but can copy the file
by
> UNC path in a command prompt.
>
> Thanks anyway
>
>
> Benjamin Johnston <s355171@student.uq.edu.au> wrote in message
> news:Pine.OSF.4.21.0008090735410.24376-100000@student.uq.edu.au...
> > > Have a java application in a Windows NT environment and want ot use
the
> File
> > > object as such;
> > >
> > > File inputFile = new File("\\server\share\filename.txt");
> > >
> > > This does not work but works if I use a mapped drive letter?  Any
ideas?
> >
> > Maybe you need to escape those slashes;
> > File inputFile = new File("\\\\server\\share\\filename.txt");
> >
> > But otherwise, no idea.
> >
> > -Benjamin Johnston
> > s355171@student.uq.edu.au
> >
>
>
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads