Any other ways to change directory in Java Application??

As Runtime.getRuntime().exec("cd ..") won't work in Java
application, are there no other ways to change the current directory.
Let's say the current directory is C:\test, and you run Test1.class
C:\test\java Test1
In Test1.java, you try to change the current directory to C:\helloworld.
Is it possible???

y do you want to chnge the current dir???
if you want to access files then u can do that from ur current directory. simply create a file object using the absolute file path to the file
for example if u r thinking of writing to a file located in c:\file and ur program is currently in c:\myProgram then u just have to create a file object
file f = new file("c:\\file");
then create ur input or ouput streams using this file object and you can do wat u want with it.
even if you dont want to read or write to a file im sure you can use the absolute path to do wat you want without changing the current working dir.

Similar Messages

  • I can no longer change my song names like i used to. i use to be able to right click and go to "get info" and then change the song name, artist and album, now i can't is there any other way to change the songs name and info

    When I get songs and put them on my itunes accout on my computer I used to be able to rename them right clicking, going to "get info" and then renaming everything I wanted like song name, album and artwork. I also use to be able to click on the song then click and hold on it and be able to rename it. But all the songs I have gotten after the last update have not been able to be renamed in any of the old ways I use to be able to. Is there any other way to rename songs because I know I can't undo updates and that seems to be whats causing it.
    Thankyou for your time

    You are describing an iTunes problem, not an iPod touch problem. Try posing in the iTunes forum.

  • Color Depth Choices Removed...Any other way to change?

    SL removed color depth choices in displays. We use display link adapters (USB video cards) for extra external monitors (email/web etc) and setting the display to thousands increased performance dramatically. Now we are stuck at millions...
    Anybody have some command line fu to change the display color depth?
    <edited by host>

    Sorry... No.
    See Here  >  http://support.apple.com/kb/HT1808
    You may need to try this More than Once...

  • How Can I change my country location  without using my creditcard? I Cant Use my creditcard but I need it to change my country location, Is there any other way?

    I Moved to Venezuela From Canada 4 Month ago.      I had some apps on my iphone that I had to pay with my creditcard to download, I used to have the App: Wahtsapp it cost 0.99$ I bought it when I was i Canada and I coould use my creditcard, But I deleted "Whatsapp" but I was not a proble, because  I had a security copy on my computer, But I needed to Update the apps and I couldnot do it, because I had to put my payment imformation, But I actually i have some troubles with my creditcard, so i cant use it.
    is there any other way to change my country without putting my payment information, that way I can update my apps without having to put my payment information.

    You must have a valid form of payment for the app store in the country you are using. Most app stores are separate legal entities to comply with local laws. It is possible to have an account without a credit card, however; see: http://support.apple.com/kb/HT2534

  • I want to upgrade my iCloud storage, but as I'm in Spain it won't accept an English card! Is there any other way to upgrade or change country??

    I want to upgrade my iCloud storage, but as  I'm in Spain it won't accept an English card! Is there any other way to upgrade or change country?? Please help!!!

    Andy,
    We are currently in the same situation as you.  Seems we have been "Spoofed",,,, e-mails "TO" us and also sent "From" us.... Both to and from using our old <xxxxxx.mac.com> address.  We are getting about 15 of the e-mails a day.  All from some version of "Med Store",, "Great Medical Store",, "Erect Meds Cheap",, and other variations of same.... Each one has a different "Link" in the text, but we never launch them.
    The amazing part is that for the past six weeks they all indicate that they originate from a different address.  Some foreign and some from US addresses.  So, we cannot write a "Rule" banning the originating address.
    We did write a "rule" that send them to "Junk" and forwards each one to <[email protected]>.
    Anyway,,,, we are ready to change our address, but are in the same "can't be done easily boat" as you.
    Seems we have to start all over and establish an entirely new Apple Account.  (Our old one will remain out in cyberspace forever)..... Seems strange.....
    Our reluctance remains with stuff like our Calendars, Notes, iTunes, Apple Store purchases, etc......
    We have posted questions here and on MacRumors, but seem to never get good answers.....  Most say just "live with it" and maybe it will stop.
    And like you we found out about using Alias' to late... shame on us....
    Very confusing and frustrating.....Still open for any input....
    Mike

  • I changed my passcode on my IPhone 5 and have forgotten it. I'm not able to connect to itunes to factory reset it so, is there any other way in which i can factory reset it?

    i have forgot my passcpde and i'm not able to use a laptop which means i can't connect to itunes so i was wondering if there is any other way in which i can factory reset my phone manually.

    Follow the directions here to force your phone into recovery mode & restore it:
    http://support.apple.com/kb/ht1212
    This will remove the passcode.

  • My iPhone 4s notified me that I had to manage my storage  so I deleted  apps that used a lot of space I deleted almost all my picture and it still keeps telling me  I don't have enough storage  is there any other way I can make room on my phone ?

    My iPhone 4s notified me that I had to manage my storage  so I deleted  apps that used a lot of space I deleted almost all my picture and it still keeps telling me  I don't have enough storage  is there any other way I can make room on my phone ?  Were it shows how much storage  I have available it still says 9.9 even after all that I have done so I don't know if I need to change my storage plan or what but anything will help I guess

    Check for 'others' in iTunes against your iPhone.
    Restore from a previous backup to reclaim some of it.
    Still want more, Restore in iTunes, setup as New.

  • Is there anyway I can use my iPod Touch serial number or Apple ID to trace and find back my iPod Touch? Cause I lost it recently(as you know iPod Touch can only go online if there is WiFi). is there any other ways too, apart from contacting the police?

    Is there anyway I can use my iPod Touch serial number or Apple ID to trace and find back my iPod Touch? Cause I lost it recently(as you know iPod Touch can only go online if there is WiFi). is there any other ways too, apart from contacting the police?Is there anyway I can use my iPod Touch serial number or Apple ID to trace and find back my iPod Touch? Cause I lost it recently(as you know iPod Touch can only go online if there is WiFi). is there any other ways too, apart from contacting the police?

    No.
    - If you previously turned on FIndMyiPod on the iPod in Settings>iCloud and wifi is on and connected go to iCloud: Find My iPhone, sign in and go to FIndMyiPhone. If the iPod has been restored it will never show up.
    iCloud: Find My iPhone
    - You can also wipe/erase the iPod and have the iPod play a sound via iCloud.
    - If not shown, then you will have to use the old fashioned way, like if you lost a wallet or purse.
    - Change the passwords for all accounts used on the iPod and report to police
    - There is no way to prevent someone from restoring the iPod (it erases it) using it unless you had iOS 7 on the device. With iOS 7, one has to enter the Apple ID and password to restore the device.
    - Apple will do nothing without a court order                                                        
    Reporting a lost or stolen Apple product                                               
    - iOS: How to find the serial number, IMEI, MEID, CDN, and ICCID number

  • Western Digital My Book World EditionI have bought a WD My Book World Edition to use for back-up of my iMac, but when I try and log onto the drive with Apple time Machine (back-up software) or connect in any other way i get the message 'There was a proble

    I have bought a WD My Book World Edition to use for back-up of my iMac, but when I try and log onto the drive with Apple time Machine (back-up software) or connect in any other way I get the message 'There was a problem connecting to the server "MybookWorld.local" The version of the server you are trying to connect to is not supported. Please contact your system administrator to resolve the problem'
    It is a brand new iMac and running Lion OSX
    Any ideas on how to solve would be gratefully received?

    Followed the directions on this page and it worked!
    http://forums.macrumors.com/showthread.php?t=1102423
    Part One - Turn on SSH (in the admin panel)
    [1] Go to to http://mybookworld.local
    [2] login: username will be admin, password will be whatever you have setup. If you can't remember it should be in your Mac OS X keychain (Utilities > Keychain Access, search for "mybookworld"). If you have not changed if from the default the password will be admin as well.
    [3] Switch to advanced mode.
    [4] From the System tab, pick Advanced.
    [5] Enable SSH Access, and click submit.
    [6] Click on the network tab and then the LAN button
    [7] Make a note of the IP address
    Small, maybe obvious, but nevertheless important point: For the install to work, your NAS needs to be connected to a router with internet access.
    Part Two - Install netatalk2.2
    [8] Open Terminal.app (Utilities > Terminal)
    [9] Enter the following command (substitute in 127.0.0.1 for the actual IP address you noted down in step 7), then hit return:
    Code: 
    ssh [email protected]
    [10] When prompted, enter the ssh password (will be welc0me).
    [11] You are now going to download the installer. Enter the following command, then hit return:
    Code: 
    wget http://mybookworld.wikidot.com/local--files/netatalk2-2-on-whitelight/install_netatalk.sh -O install_netatalk.sh
    [12] Once completed, you will need to run the installer. Type:
    Code: 
    sh install_netatalk.sh
    [13] You will be asked a number of question during install, answer yes to all. When asked about the "DHX2 login process", I opted to install the modified version, so I can confirm it works.
    [14] Once the box has restarted, you should be able to connect to your afp shares and continue to use Time Machine.

  • My wifi button is frezon and I tried turning my phone off for a period of time and reset my phone but the button is still frezon it want slide over to turn on my wifi. Is there any other way to fix without going to apple to get it fixed?

    My wifi button is frezon and I tried turning my phone off for a period of time and reset my phone but the button is still frezon it want slide over to turn on my wifi. Is there any other way to fix without going to apple to get it fixed?

    Hey Posada143, You can still try the rice thing, but do not expect much, as roaminggnome has stated. The rice only works if you do it ASAP and leave the iPod off-- do not attempt use, turn on or charge until it is completely dried out. This is probably academic at this point but remember this for the next time: The drying can take 10 days. You put the uncooked rice and iPod in a sealed bag, change the rice every couple of days. This creates a low humidity environment and draws the moisture out of the iPod, but it takes time. Turn your iPod on to earlier, and you run the risk of shorting out, damaging the components inside. Even if done correctly it can spotty. If you do get the iPod to work (and this may require Resetting, Restoring or attempting to place it in DFU recover mode) the first thing you do is make backups, because you never know how long it will continue to work. As for your pictures, if you can't get your iPod to work, you can try data retrieval companies, however; there is no guaranty it will work and it tends to be very expensive. In the future get in the habit of as making backups, because you just don't know. And invest in and use a water tight case. Hope this helps, Good luck. Cheers.

  • How you change directory in Java

    Can someone tell me how to change directory in java ?
    Sample code would be much appreciated.
    Thanks in advance.

    Maybe you could explain why you think you need to change the directory. Then a solution to your actual problem might appear.

  • My daughter ipod touch has been missing for at least a month, tried the find my iphone but her battery is dead is there any other ways to find it??

    My kids ipod touch 4 has been missing for 2 months I tried the find iphone app but her battery is dead so I get no sound or signal, is there any other ways to find it??

    Only the old fashioned way, like if you lost a wallet or purse.
    - Change the passwords for all accounts used on the iPod and report to police
    - There is no way to prevent someone from restoring the iPod (it erases it) using it.
    - Apple will do nothing
    Reporting a lost or stolen Apple product                              
    - iOS: How to find the serial number, IMEI, MEID, CDN, and ICCID number

  • HT203167 Any other way to recover music

    I lost all my music from my itunes account. I found that most of my music is under my older apple ID.  When I logged in it said I had to wait 90days to change the ID. Is there any other way I can recover my music?

    Have you failed to maintain a backup copy?

  • If icloud is keep saying my ipod is offline is there any other way i can loate it

    if icloud is keep saying my ipod is offline is there any other way i can locate it

    See bold
    - If you previously turned on FIndMyiPod on the iPod in Settings>iCloud and wifi is on and connected go to iCloud: Find My iPhone, sign in and go to FIndMyiPhone. If the iPod has been restored it will never show up.
    - You can also wipe/erase the iPod and have the iPod play a sound via iCloud.
    - If not shown, then you will have to use the old fashioned way, like if you lost a wallet or purse.
    - Change the passwords for all accounts used on the iPod and report to police
    - There is no way to prevent someone from restoring the iPod (it erases it) using it unless you had iOS 7 on the device. With iOS 7, one has to enter the Apple ID and password to restore the device.
    - Apple will do nothing without a court order                                                        
    Reporting a lost or stolen Apple product                                               
    - iOS: How to find the serial number, IMEI, MEID, CDN, and ICCID number

  • Is it possible to track an ipod through its serial number, or find it any other way

    My ipod was stolen/lost today, i have the serial number and the find my ipod app is installed but apparently not activated. Short of going to the police is there any others way that i could possibly get it back, please make some suggestions as every little helps.
    If by a massive coincidence the person who found it is reading this (it is in a black leather flip case and is engraved with "mischief managed") contact apple to report it missing.

    The SN will only help identify the iPod as yours if it is recovered.
    - If you previously turned on FIndMyiPod on the iPod in Settings>iCloud and wifi is on and connected go to iCloud: Find My iPhone, sign in and go to FIndMyiPhone. If the iPod has been restored it will never show up.
    - You can also wipe/erase the iPod and have to iPod play a sound via iCloud.
    - Change the passwords for all accounts used on the iPod and report to police
    - There is no way to prevent someone from restoring the iPod (it erases it) using it.
    - Apple will do nothing
    Reporting a lost or stolen Apple product                               
    - iOS: How to find the serial number, IMEI, MEID, CDN, and ICCID number

Maybe you are looking for