Retrieving the path where the app is started

Hello this is my first post in here and it won't be my last ;-)
I would like to retrieve the Application current path? I can't find it how to do that!
In VB you've got App.Path.
Thnx

Using of System.getProperty("java.class.path") is not better idea. Because if your class path contains some additional paths (dependence from using libraries, for example), then this property will contain all paths separated by ":" for Linux and ";" for Windows OS.(*"/program/class/path:looks-1.3.1.jar:etc"*)
Besides, if, for example, you using Eclipse for development, in project your classes stored in *.../ProjectPath/bin* directory, but if you start you application from jar-file, then first path in property *"java.class.path"* will be contain *.../PathToJar/you.jar* - it necessary call *.getParent()* for get final path and do not forget to check on null for case when application started from program-bin directory.
*"user.dir"* - it is current dirrectory. I guess it same as new File(".").getAbsolutePath(); In development you get right result, but after deployment of application you will be surprised. It is not good idea too.
Now I am parsing *"java.class.path"*, but it is not flexible solution. I hope program bin path always first in this property.
Does somebody know better solution?
Maybe it is possible to get this information from VM.
I need to retrieve this path, because by this path usually I am storing "Data" directory which contains different resources for application.

Similar Messages

  • HT201301 I haas this app b4 resetting my phone. I retrieved the app but I cannot get the full pro version again. I need to know how to get the full pro version back sobi can get started re downloading my playlist please

    I downloaded a music download app. I had to reset my phone  I retrieved the app but cannot retrieve the full version I had already purchased. The pro version. How do I get the pro version back? I've tried everything

    Downloading past purchases from the App Store, iBookstore, and iTunes Store

  • When I am connected to the WiFi, my apps cannot be download. Once I had disable the wifi and connect directly to the service provider, the apps will start to download. Please advise what is the problem and solution for my iPhone 5.

    When I am connected to the WiFi, my apps cannot be download. Once I had disable the wifi and connect directly to the service provider, the apps will start to download. Please advise what is the problem and solution for my iPhone 5.

    I can't follow your meaning. What does connect directly to your ISP mean?
    Did you mean turning off WiFi but turning on Cellular Data on your iPhone?

  • Two apple identifiers make it impossible for me to retrieve the apps

    Hi,
    two apple identifiers make it impossible for me to retrieve the apps
    that I had from a previous macbook and iphone to the new macbook. HOw do I get to get my apps back on both devices since itune wont let me retrieve the info with the previous identifier?
    thanks for the help
    Annie

    Hi anniehillairet,
    Welcome to the Support Communities!
    The article below may be able to help you with this.
    Click on the link to see more details and screenshots. 
    Using your Apple ID for Apple services
    http://support.apple.com/kb/HT4895
    I have purchased music, apps, or books with multiple Apple IDs. How can I get all of this content onto my iOS device?

    First, you need to copy all of your purchased content so it is on the same Mac or PC with iTunes. This computer should be the one you sync your device with. For more information on how to move your content, see these articles:
    Mac:  iTunes for Mac: How to copy purchases between computers
    PC:  iTunes for Windows: How to copy purchases between computers
    Next, authorize your computer to play content with each Apple ID in iTunes. Once your computer is authorized for all your content, it can be synced to your iPhone, iPad, or iPod touch.
    Cheers,
    Judy

  • Hello I have the App: Global Navigator1,5 and thye new 1.7 bought yesterday. I have made an update at my mobile. Since this time the app dont start.

    Hello
    I have the apps globel navigator V1.5 and V1.7.
    Since i hvae made the update to io6 the apps dont start.
    I have payed for both Apps.
    Can you give me a tip for usething is apps again?
    Thanks Jörg

    You have to contact the developers of the apps. See if they have a new update that runs in IOS6.
    There's nothing a user to user forum can do.

  • I have 2 apple ID's can I retrieve the apps and songs from both accounts to my iphone?

    Hi,
    I have an ITunes log in from my ipod that is around 3 years old. Last year work bought me an ipad and I set up another apple ID account and downloaded app's for the Ipad. Yesterday I got a new Iphone 4s and logged into the app store through the same apple id as linked to my ipad. 
    My question is can I sync the music from my ipod and the apps from my ipad onto my new phone? And to sync my phone do I have to do it through my works PC where the Ipad has been set up or can I do it on my home PC which has itunes installed?
    I hope that someone understands this and can help. Thank you. 

    Apps are tied to the Apple ID, so you can't use apps from different Apple IDs on one device.

  • Trying to update Mac OS X 10.8.5 on a Mac Pro 2010 platform.  The App Store starts the downloading, than stops.  Error (102).  Any idea what goes wrong?  Thx

    Just installed Mac OS X 10.8.5  on a Mac Pro 2010 platform. 
    The App Store shows there is an upgrade, so I click the download button. 
    After about 2 hrs the process stops and an  Error (102) appears on the screen. 
    Any idea what goes wrong? 
    THX

    You just now installed 10.8.5? Did you purchase that at the app store?
    What is the upgrade being offered?
    FWIW, you are not running iOS on a Mac Pro (we are talking about the desktop tower Mac Pro, right?)

  • Hello every time i launch the app it starts to load then disappears on my macbook air help

    the app pops up with the load page then just crashes ....

    Louiseh81773106 what Adobe software title are you trying to open?  Do you receive any specific error messages?  Finally what operating system are you using?

  • Can I change the path where my app reads native code?

    I have created an application that is using a native code file. It is (that is the DLL file) stored in the JDK folder in (jdk1.6.0_16\jre\bin) and my application reads from there.
    Is it possible to make the application to read the native file from somwhere else? From the JAR file?

    You can get the VM to look for native files (DLLs on Windows, SOs on Linux) by specifying
    java -Djava.library.path="path to your DLL/SO" etc. when you start your app.

  • Anything I try to do on my iMac is suddenly slow and I typically get the pinwheel or it takes a few minutes for the app to start. This includes just typing into an email or pages doc etc.

    I was using WildBlue Satellite service for my internet connection. I recently changed to a Broadband connection. Since the change my computer is slow. I click on the mail application icon (or any other icon) and then wait and wait for it to open. It used to be instantanious. While I am editing in Pages or Numbers I will type almost an entire sentence before the characters actually appear on the screen.  This happens when I am typing an email as well. I often get the pinwheel and cannot do anything until the system catches up with me. It doesn't make sense that the broadband connection has anything to do with this. My internet upload and download speeds are great.  It is mostly the internal apps that do not require an internet connection. Any ideas?

    I've got activity monitor open and nothing is popping out at me. But I will check it the next time I get the pinwheel.
    No software was installed - either related to the new broadband connection or otherwise. I checked for updates to the OS (nothing).
    I tried turning Airport off and at first it seemed better and I also did not have the ethernet connected.  I also did an SMS reset? No change.
    Good suggestions though.
    Oh, I am running Parallels6.  I've shut windows down, performed a clean disk and system clean with Trend Micro. 
    Message was edited by: christinefrommountainair

  • How do i limit the apps that start when Xperia Z boots up? phone

    Other than individually....

    Hello Condukta,
    Here is a link to the Sony Mobile Group who could assist with your question about the Z phone.

  • I was playing "design this home" and made a mistake so I deleted the app but when I go into the app store  to re install it it's says it's "install" instead of "free" how can I restart the whole game

    As it says in the heading can anyone help?? I wanna start the game again but it keeps going back to where I was up to :-(

    I don't know the app, but am guessing here.
    Disconnect from the internet after you have reinstalled the app.
    Start the app with data and wifi turned off.
    This could help.
    I am assuming it updates your data from the cloud.
    There must be also be an option to reste the settings.
    Or contact the programmer.

  • "Devices running,press if you want to know more or stop the app"?

    What is this and how do i stop it?
    It pops up every time I start Internet. Pressing it will only get me to the appsettings where i can uninstall or stop. If i stop the app, it starts up again after a while. Guess it's someone sharing service, but I have not started anything to share with ex. dlna. 

    Hi and welcome to the community! Since you're new please be sure that you have checked out our Discussion guidelines.
    Check if you have Media server enabled.
    Settings > Xperia connections > Media server.
    If not yo probably have a computer on your Wi-Fi network that act as an DLNA server.
    Or do this also happen when connected to 3G/4G networks? I can see by your screen shot that you're connected to a Wi-Fi network.
     - Community Manager Sony Xperia Support Forum
    If you're new to our forums make sure that you have read our Discussion guidelines.
    If you want to get in touch with the local support team for your country please visit our contact page.

  • My Photos app isnt working, at all. Should I delete the app and reinstall???

    I downloaded the app and started the process to import my pics. But it froze. I force quit and try to bring it up, but it wont launch the program. What should I do?

    I downloaded the app and started the process to import my pics.
    Where do you import from? Are you migrating an iPhoto Library or an Aperture library? Or a folder of photos?
    Check, if Photos can launch at all. The problem may be a corruption of the Photos library. so test with a new library.
    Hold down the alt/options key ⌥ and click the Photos icon in the Dock simultaneously. This will bring up a Library Chooser panel. select to create a new library.  If Photos can launch on a new library, post back with your results and more information on the library you migrated.

  • I downloaded IOS6 and all my apps, including the App Store icon, disappeared. If I go to the Passport icon, there is an App Store button, but I have to search through all the apps to find the one I want  and then click on "Open" to use it.  Help!

    I downloaded IOS6 and all of my app icons, including the App Store icon disappeared. Now to use an icon, I have to go to Passport and click on the App Store button at the bottom and search through all of the apps to find the one I want and then click on Open. There doesn't seem to be a way to delete the app and start over.

    Hey PlayerPS,
    Thanks for the question, and welcome to Apple Support Communities.
    It sounds like the application you are looking for is indeed still on your iPhone. You can confirm this by searching in the Spotlight Search for this application. It may have accidentally been moved to a folder, or an additional Home screen:
    iOS: Understanding Spotlight Search
    http://support.apple.com/kb/HT3636
    via http://manuals.info.apple.com/en_US/iphone_user_guide.pdf
    Thanks,
    Matt M.

Maybe you are looking for

  • Intall Error - Adobe Acrobat X Pro - Mac OSX (10.8.4) Mountain Lion

    Hi, I cannot install Adobe Acrobat X Pro on my Mac running Mountain Lion. The install file is through my university. The Installer runs like normal but end with the following screen: I can send the lntall log if necessary. I have turned off Gatekeepe

  • While executing ObjectTag in flash.htm, a javascript error occurred

    I'm attempting to place a SWF file in an editable region on a page created from a template.  I get the error: While executing ObjectTag in flash.htm, a javascript error occurred.  I saw on another sight that someone found the problem which was editab

  • Keyboard shortcut for opening the spelling suggestions menu?

    On windows one can use the keyboard button for a right-click in order to open the spelling pop up menu in programs such as Word. Is there any similar way to open the spelling suggestions for the global OS X spell checking via the keyboard? Thanks!

  • DWS grouping in V_T508A- Urgent

    hi Everyone, I am trying to create a New work Schedule Rule through the Table V_T508A. but when Iam creating new entries , the grouping for daily work schedule appears to be grayed out field and already there is an entry there. Please tell me how to

  • Dialing with a Pause not working

    Hello, I know there are other post about this problem,but, does anybody heard from apple about a solution for this? Thanks!