Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Java > changing working directory?

Reply
Thread Tools

changing working directory?

 
 
hack_tick
Guest
Posts: n/a
 
      10-24-2005
hi there!
I am looking for changing the working directory, using j2se methods is
it possible?

 
Reply With Quote
 
 
 
 
Roedy Green
Guest
Posts: n/a
 
      10-24-2005
On 24 Oct 2005 00:56:11 -0700, "hack_tick" <(E-Mail Removed)>
wrote, quoted or indirectly quoted someone who said :

>hi there!
>I am looking for changing the working directory, using j2se methods is
>it possible?


No. Part of the problem is defining what it would mean if thread A
changed it. What does thread B think?

What you do instead is define your own default directory, and in the
simplest case just feed it to File( dir, file) as the first parm.
--
Canadian Mind Products, Roedy Green.
http://mindprod.com Again taking new Java programming contracts.
 
Reply With Quote
 
 
 
 
Andrew Thompson
Guest
Posts: n/a
 
      10-24-2005
hack_tick wrote:

> I am looking for changing the working directory,


You're looking for the wrong thing*. Why do you
think you need that?

* A 'NetworkClassLoader' (see ClassLoader docs.)
and a FileDialog or JFileChooser can get at any
resource in the local file system, permissions granted.
 
Reply With Quote
 
hack_tick
Guest
Posts: n/a
 
      10-24-2005
m...i was using Runtime.exec i forgot it had overloaded method,

public Process exec(String[] cmdarray,
String[] envp,
File dir)
throws IOException

it seems i didnt do my homework

sorry for any trouble

 
Reply With Quote
 
hack_tick
Guest
Posts: n/a
 
      10-24-2005
thx a lot, i will keep note of those

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Changing style of the numbers in a CSS <ol> without changing the style of the <li> Aaron Beall HTML 2 09-14-2007 08:07 PM
<FAQENTRY>I'm changing my page but nothing is changing on the screen. Why?</FAQENTRY> VK Javascript 3 03-15-2007 04:59 PM
postbacks not working after changing namespace abcd ASP .Net 0 08-03-2005 10:54 PM
changing file extension without changing filename jamy Computer Support 4 03-04-2005 01:03 AM
Difficulty in changing the Connection Server control path changing ... Samridhi Kumar Shukla ASP .Net 1 11-30-2003 02:31 AM



Advertisments