• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to connect to remote file without socket  RSS feed

 
ahmedali mohd
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,

Can any one help me out to create a file on network system without socket options


 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What kind of access do you have to the remote server - shared directory, WebDAV, FTP, HTTP, ... ?
 
ahmedali mohd
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I 've a shared directory for that server on my machine... I want to create the file or if exists ...i want to read it ...

Thanks for your reply ....Please help me out.....
 
ahmedali mohd
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

I 've write access to that shared directory as well... Please provide me the code... I m trying URL class and getURLConnection also but it is giving me errors...
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you're getting errors, then you should post the stack trace here, along with a short, relevant excerpt of the code that produces it.

What OS is on your machine, and what OS is on the server?
 
Rob Spoor
Sheriff
Posts: 20895
81
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ahmedali mohd wrote:I 've a shared directory for that server on my machine... I want to create the file or if exists ...i want to read it ...

You can try java.io.File. On Windows:
If the security does not allow you to access the file you can check out JCIFS. That allows the same but using explicit security credentials.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!