Running with external library

When I run my program on the command-line prompt, how do I include the external library archived in jar files? I developed my project using an IDE and it runs fine in the environment created by the IDE. But I am having trouble running it directly from the command-line... The VM seem to have troble locating the external library that I included... Does anyone know the answer? Thanx!

Yes, you can, but I don't think you may.
There are two options:
1. unjar all your external jars to a directory and add that to your classpath
2. add all your jars to your classpath
You can also use your classpath environment variable:set classpath=<your classpath>or set in in Windows (which I assume you're using, because you're using SQL Server as well), so that you don't have to specify it for every compile/run command.
Kind regards,
  Levi

Similar Messages

  • Problem with external library DC

    Hi,
    I am working on NWDS Version: 7.02.06.
    I am trying to use JXL jars in my DC and have used the blog /people/bertram.ganz/blog/2008/11/24/how-to-use-external-jar-files-in-web-dynpro-development-components to achieve this.
    My problem comes at the last step. When I add the Library refernce in my WD DC, i give sap.com~hkjecomp. Sap.com is my vendor and hkjecomp is the JEE (Library type DC) wrapping the External lib DC.
    When I deploy the WD DC, it deployed with warnings and a cluster wide exception :
    Aug 5, 2011 5:41:12 PM /userOut/deploy (com.sap.ide.eclipse.sdm.threading.DeployThreadManager) [Thread[Deploy Thread,5,main]] WARNING:
    [011]Deployment finished with warning
    Settings
    SDM host : sapdapp1
    SDM port : 53918
    URL to deploy : file:/C:/DOCUME1/hkandpal/LOCALS1/Temp/temp28228sap.com~hktest02.ear
    Result
    => deployed with warning : file:/C:/DOCUME1/hkandpal/LOCALS1/Temp/temp28228sap.com~hktest02.ear
    Finished with warnings: development component 'hktest02'/'sap.com'/'local'/'20110805174050'/'0':Caught exception during application startup from SAP J2EE Engine's deploy service:java.rmi.RemoteException: Error occurred while starting application sap.com/hktest02 and wait. Reason: Clusterwide exception: server ID 398344750:com.sap.engine.services.deploy.container.DeploymentException: Clusterwide exception: Failed to prepare application sap.com/hktest02 for startup. Reason=Clusterwide exception: Failed to start dependent library ''sap.com~hkjecomp'' of application ''sap.com/hktest02''. Status of dependent component:  STATUS_MISSING. Hint: Is the component deployed correctly on the engine?     at com.sap.engine.services.webdynpro.WebDynproContainer.prepareStart(WebDynproContainer.java:1507)     at com.sap.engine.services.deploy.server.application.StartTransaction.prepareCommon(StartTransaction.java:223)     at com.sap.engine.services.deploy.server.application.StartTransaction.prepare(StartTransaction.java:171)     at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:301)     at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesImpl(ParallelAdapter.java:342)     at com.sap.engine.services.deploy.server.application.ParallelAdapter.runInTheSameThread(ParallelAdapter.java:126)     at com.sap.engine.services.deploy.server.application.ParallelAdapter.makeAllPhasesAndWait(ParallelAdapter.java:245)     at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:4741)     at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:4646)     at com.sap.engine.services.deploy.server.DeployServiceImpl.startApplicationAndWait(DeployServiceImpl.java:4619)     at com.sap.engine.services.deploy.server.DeployServiceImplp4_Skel.dispatch(DeployServiceImplp4_Skel.java:1163)     at com.sap.engine.services.rmi_p4.DispatchImpl._runInternal(DispatchImpl.java:330)     at com.sap.engine.services.rmi_p4.DispatchImpl._run(DispatchImpl.java:201)     at com.sap.engine.services.rmi_p4.server.P4SessionProcessor.request(P4SessionProcessor.java:137)     at com.sap.engine.core.service630.context.cluster.session.ApplicationSessionMessageListener.process(ApplicationSessionMessageListener.java:33)     at com.sap.engine.core.cluster.impl6.session.MessageRunner.run(MessageRunner.java:41)     at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)     at java.security.AccessController.doPrivileged(Native Method)     at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:104)     at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:176) (message ID: com.sap.sdm.serverext.servertype.inqmy.extern.EngineApplOnlineDeployerImpl.performAction(DeploymentActionTypes).REMEXC)
    Deployment exception : Got problems during deployment
    While trying to add the Library reference, I have also tried with sap.com/hkjecomp.
    I have asked the basis guys to find out if the JEE application is running or not, but meanwhile can someone suggest if anything else could have gone wrong.
    Thanks,
    HImanshu

    Hi,
    Please check below link on how to use external library in Web Dynpro.
    [http://www.sapgeek.net/2010/10/web-dynpro-java-use-external-library/|http://www.sapgeek.net/2010/10/web-dynpro-java-use-external-library/]
    And you can find more information on Web Dynpro from here:  http://www.sapgeek.net/sap-tutorial/web-dynpro-java-tutorial/
    Regards,
    Andy
    Edited by: Andy Zhao on Aug 6, 2011 1:47 PM

  • ITunes album artwork screen saver possible with external library?

    I just moved my iTunes library to an external drive to free up space on my MacBook, and I was wondering if there's a way to still use the album artwork screen saver when the external drive is not connected? I still have my artwork folder on my internal drive but when it is not connected, it says, "Your iTunes Library does not contain any songs with artwork." Is there a place where the screen saver info is saved? or does it only work with the library itself?

    hi,
    it will only work when your library could be available.
    beside, if I may suggest, it is more reliable to place your library files on your external drive along with your songs than keeping the library files on the internal drive. that way, you will avoid the issue to mistakenly open your library while your external drive isn't mounted.

  • Problem with External Library

    Hi Everybody
    I'm using NW04s (7.0) sp 11 and I'm having problem using an <a href="http://sourceforge.net/projects/jexcelapi/">external jar</a>
    for reading and writing to excel files. (I already used this jar with a regluar WD project and now I want to use it in a Web Dynpro DC project).
    I tried using <a href="/people/valery.silaev/blog/2005/09/14/a-bit-of-impractical-scripting-for-web-dynpro blog</a> and <a href="/people/bala.krishnan2/blog/2006/09/25/bid-adieu-to-bots--using-captchas Blog</a>.
    I tryed following both step by step, but when I tryed to use my project I get Class Not Found Error. The library is being created but it doesn't contain any jars.
    I'll will give ten points for anyone who will guide me step by step how to deploy an external library in NW04s
    Maybe something changed in this version??? Or this Jar isn't suitable for SAP J2ee server
    Regards
                Omer

    I tried this blog and had 2 problems.
    1.)
    I didn't understand this part from the blog
    "Caveat confector:
    One should always remember this significant and valid point: 'Use ONLY DC Builds to create the deployable archive if you work with assembly public parts."
    What should  I 'DC Build' the  'Web Dynpro DC' or the 'external library DC'?
    It isn't clear.
    2.)
    When I tried now to do it, I followed the blog and I get this warning when trying to build External Library DC.
    "17/06/2007 10:02:09 /userOut/Development Component (com.sap.ide.eclipse.component.provider.listener.DevConfListener) [Thread[ModalContext,5,main]] WARNING: jexecel_lib: Compute DC build order: skipping DC that could not be loaded: MyComponents:sap.com/jexecel_lib. Exception: Failed to read component definition from local file MyComponents:sap.com/jexecel_lib : Cannot read component definition. File does not exist: D:\Documents and Settings\omers\.dtc\LocalDevelopment\DCs\sap.com\jexecel_lib\_comp\.dcdef (Cannot read component definition. File does not exist: D:\Documents and Settings\omers\.dtc\LocalDevelopment\DCs\sap.com\jexecel_lib\_comp\.dcdef)"
    what is the reason, for this warning?

  • Extending BO with external library

    Hello,
    Is it possible to extend the functions available on BusinessObjects with third-party libraries?
    For instance, we want to extend BO with a library with complex mathematical functions and have these functions available to the user on the interface.
    Is this possible?
    How can we do this?
    What requirements must the library fulfill in order to allow seamless integration?
    Thank you,
    Marco Ribeiro

    Hi Falvio,
    There have been a lot of similar posts in this regard.
    Check this link..This might provide you one of the solution
    Re: Using a J2EE Server Component -> Library
    Regards
    Bharathwaj

  • Setting up Eclipse with external library (RePast libraries)

    Hi, all!
    I need to use a set of jar files built to help me creats agent-based models in Java. The jar files are part of the RePast library http://repast.sourceforge.net/
    I successfully wrote and ran a Hello World to make sure Eclipse was running Java just fine; Hello World worked perfectly.
    I have tried to import the jar files into Eclipse by creating a new project, going to Project>Properties>Java Build Path, navigating to the RePast J library jar files, importing them by pressing "Import External Jars", going to the Order and Export tab, selecting all, unselecting the JRE, pressing OK, and writing a simple testRepast class, but asking it to import RePast libs with "import uchicago.src.sim.engine.SimpleModel;" as a simple test to see if Eclipse can find my RePast jar files and use them when compiling my project. I get the error message "import uchicago is unresolved"
    import uchicago.src.sim.engine.SimpleModel;
    public class repastTest extends SimpleModel
         public static void main(String[] args) {
              // TODO Auto-generated method stub
    System.out.println("This class is successfully importing RePast.");
    }Am I correctly importing and calling on my RePast jar files?
    Thanks!

    Hmm, not sure why you are having that issue. Might try to Project > Clean.. (or Rebuild) to see if that helps.
    Also what version of Eclipse are you using?
    Here is how I add external jars to the build path:
    1. Right-click on the project and choose Properties
    2. Choose Java Build Path
    3. Click on the Libraries tab
    4. Click Add External Jars
    5. Navigate to and select the jars
    6. Verify the jars are selected and click OK to rebuild the project

  • Optimum set-up with external library and iTunes Match

    I'm a little frustrated with iTunes Match and iTunes, as it doesn't seem to play nice with libraries stored on an external disk on a network. Here's my current set-up, and any tips on how to eliminate some of the steps I have to take would be much appreciated.
    Set-up:
    One iTunes Media folder stored on external network drive at home
    Another iTunes Media folder, titled "Away from Home", stored on Macbook
    iTunes Match is turned on and has all songs (that qualify) uploaded onto it
    Own multiple devices that access iTunes Match
    If I leave my network and want to use iTunes Match, I have to:
    1. Turn off iTunes.
    2. Option-click iTunes and hold option to select a library.
    3. Choose my "Away from Home" library (or create a new one for those who haven't done this already)
    4. Sign in to iTunes, Turn on iTunes Match and add my computer/library to iTunes Match
    5. iTunes Match does it's thing which obviously means it adds 0 songs due to having an empty library, then all my iTunes Match songs populate my library
    That is all fine and great. However, when I return home and want to listen to ALL songs, meaning those that didn't qualify and the unedited versions (since iTunes Match STILL pushes clean versions of songs), I must take these steps:
    1. Turn off iTunes.
    2. Option-click itunes and hold option to select my library on external network drive
    3. iTunes loads up, but only loads ~16,000 of 19,000 songs
    4. Turn iTunes off again.
    5. Open Finder, hold option when I click Go in menu bar, go to Library<Preferences and delete the com.apple.iTunes.plist file.
    6. Open iTunes again, this time not holding option
    7. iTunes opens as if it's been updated or newly installed (meaning it asks if I agree to the T&SA).
    8. All songs now found and appear
    This is downright stupid. I shouldn't have to take all of these steps to do each of these. It may not sound like it takes a long time, but when you come home and want to turn on music while cleaning, entertaining friends, etc., taking these steps is a hassle and makes iTunes become a chore to run. Is there not a way to simply access my songs in the Cloud without closing iTunes and having to choose a different library? Or are these really the only steps I can take to access music from home and, subsequently, when I get back home?

    See:
    Syncing to a "New" Computer or replacing a "crashed" Hard Drive: Apple Support Communities

  • ITunes Artwork missing with external library

    I have a Seagate GoFlex Home and it happens to have an iTunes Library.
    So I started putting some of my music onto the drive and when the iTunes do recoginse it, the album artwork is missing. So far I have only put up few albums that I have because I am very picky about my music and I do need artwork. However, when I play a song, the artwork apears in the playing section, but not in the library.

    hi,
    it will only work when your library could be available.
    beside, if I may suggest, it is more reliable to place your library files on your external drive along with your songs than keeping the library files on the internal drive. that way, you will avoid the issue to mistakenly open your library while your external drive isn't mounted.

  • Syncing with external library

    I recently added a whole bunch of music to my itunes library, but I keep the music files on an external hard drive (so about half my library is kept on my computer, the other half on the external). When I plug my ipod in, even when the external HD is also connected, the music from the external doesn't sync onto my ipod. Is it possible to make all the music sync? If so, how would I go about doing that?

    I would try changing where your library is to the external, and then consoldiating your library to the external and syncing again,

  • Using iphoto with iphoto library on external hard drive

    My Imac is running snow leopard with ilife '11. I have imported way too many photos into Iphoto which is really slowing it down. I'd like to put all of my photos on an external hard drive and use that as my iphoto library--which should be possible, as I gather from reading various other related posts. Another reason to put it on an external drive is so that I can use my new macbook air to edit/organize while on the go.
    1. How do I set up my Iphoto library on an external hard drive?
    2. How do I make sure that all future photos go to the library on that external hard drive?
    3. How do I run Iphoto with the library on an external hard drive?
    THANK YOU for your help!

    Hello. I just transferred my iPhoto library to a Western Digital My Book for Mac external hard drive. Do you know if I needed to format this drive even though it says it's for Mac. I did not format it and there were not any instructions with the drive that said I needed to do it. The transfer seems to have worked ok but my backups from Time Machine onto Time Capsule are inconsistent. I already posed a question regarding this problem but I noticed this message regarding formating the external disk and I wonder if that is causing the problem. Thanks.

  • PC to Mac: iTunes Library Running on External Hard Drive

    Good afternoon all. I just purchased a MacBook 13-inch Aluminum (Late 2008) and am having some trouble with my iTunes library.
    On my PC Laptop, I am all set up to run iTunes from an external hard drive, with the library files saved on the external drive as well.
    I have searched the internet extensively, but have not found any successful way of loading iTunes on my new Mac while maintaining the date added and play counts.
    Apple offers a support document on moving the iTunes library from one computer to another (which is how I moved my iTunes folder off to the external drive), but this doesn't seem to work from PC to Mac.
    Do any of you have experience moving your iTunes Library from a PC to a Mac while maintaining your date added and play count data?
    Any help that you can provide will be greatly appreciated.
    Thanks.

    Ok, so for those of you that are interested, I figured it out.
    I first started iTunes on the new mac and got everything set up, with the library and .xml files in the ~/Music/iTunes folder.
    I then opened iTunes and went into preferences, moving the location of the iTunes music folder to the correct location on the external drive (at this point iTunes is pointing in the right direction, but has nothing in the library.)
    Next, I deleted the library and .xml file from the mac, and copied over the PC itunes library and .xml files, removing the .itl extension from the PC library file.
    Using the mac text editor, I opened the PC .xml file, and replaced all references to the external drive in PC speak (drive letter format) with mac speak (volume format.)
    Now, when I opened iTunes it began updating the library and when it finished, all of my music was there with the correct play counts and dates added. Of interesting note, while it clearly used the PC library and .xml files in some facet, it created new mac files in the same location, moving the PC library file to 'Previous iTunes Libraries', and renaming the .xml file.
    Finally, I closed iTunes and used finder to move the new mac library and .xml files off to the external drive, dropping the original PC files into a PC folder, should they ever be needed again. I opened iTunes holding option and pointed it to the new library file on the external drive.
    Now everything is up and running from the external drive on the mac, just as it did on the PC. It was a bit of a headache to keep all of the information intact, but for me it was worth it. (If you don't care about your dates added and play counts, you could of course simply add the iTunes folder from your external drive to the new mac's iTunes and avoid all of the 'fun', but I've got years of data, and like to know when I added what, and how often I actually listen to it :))
    Thanks.

  • Library management with external hard drive

    I have a 120GB external hard drive, where I store all of my music, audiobooks, videos, etc. When I created my iTunes library, everything worked great and I loaded my media into my Video iPod.
    But, the next time I plugged my external hard drive into my laptop, the library "cannot find" any of the files. So, if I want to copy anything over to the iPod again, I have to delete and recreate the library.
    Any thoughts on how to make this work so the link to a library on an external hard drive remains permanent?

    Using an ExHD is no problem. However, you should note several items:
    - The ExHD should always mount as the same drive letter. If not, iTunes will lose the references (you'll get the '!')
    - You must have the ExHD up and running before opening up iTunes, otherwise you may not be able to play the music and iTunes will reset the Music Folder to the default (on the C: drive).
    - It may be best to remap the ExHD to a letter that will never be taken by any other peripheral you attach. Use something like 'M'. That way, if you plug in something else before turning on the ExHD, the expected mount letter will still be available. Also see: How to change drive letter assignments in Windows XP
    I run a dual Library with Lossy files on my Laptop's internal drive and Lossless files on my ExHD. I have it mounting as 'L' and have never lost the references within iTunes.
    If I do have the ExHD disconnected (most times), and select a Lossless song, I will get the '!', but the next time I open iTunes with the ExHD properly attached, those 'broken links' go away.
    I would guess that you are mounting the ExHD as different drive letters from time to time.

  • Help with iTunes Library and External Music Management

    Okay, this nightmare has been getting worse and worse over the past few weeks so let's break it down so people can understand what I'm trying to do.
    1) I have music on both my internal laptop drive and external drives.
    2) I want to have two libraries, one for the internal drive featuring all the music on my internal drive (and possibly some stuff on the external since that's how it currently is), and the other which is ALL my music from all my drives.
    3) I want all new podcasts/itunes store content to save to my external drive.
    4) I want the iTunes music folder to reflect which library I'm running (that is to say, if I am in my internal library, the iTunes music folder would be on the internal drive so if anything is copied to "itunes music library" it would copy to my internal, if on the external drive the itunes folder would be on the external drive and anything copied would end up there)
    5) I want iTunes to keep each library organized.
    6) for my External library I would LOVE to keep all my playlists, and iTunes store purchases in the library (something that didn't happen when I created a new library)
    IS THIS POSSIBLE!?!
    Basically here's what i did in the past. created a new library on the external and added all my music on the external to it. this caused it to organize everything fairly nicely. I then copied imported the XML data from my old internal library so I would get my playlists and iTunes store stuff to show up, along with anything on the internal drive. this cause MAJOR duplication issues (i have 3 copies of songs now in my external drive which Im going to have to sort through). I tried multiple libraries but everytime I switch back and forth my iTunes music folder keeps changing. (ie. the folder location will carry over to any library - not stick to just the one) This is a HUGE pain in the ###.
    Basically, if I'm on the road I want to be able to open iTunes, it automatically launch my internal library which has everything in my internal drive, know that the music folder is "my username/music", and then when I come back home and able to plug into my external drive be able to launch that external library and it know that my music folder should now be "externaldrive/music".
    i cannot seem to get iTunes to save this folder preference PER library. is this even possible!?! I just want this stupid thing to work!
    Message was edited by: ehmjay

    As long as you don't have an existing library that is synced with a device or holds oodles of carefully crafted playlists, ratings etc. then...
    Hold down shift as you start iTunes. You should get an option to choose or create a library. Click create, browse to root of the external drive and click save so that your library is say X:\iTunes where X: is the letter of your external drive. All new content downloaded to the library will stay on the external drive.
    See this user tip for a backup strategy.
    tt2

  • My external 27" AOC display only runs with 1080p

    My external 27" AOC display only runs with 1080p, even though my 27" iMac is capable of 2560x1440 via the attached mini-DisplayPort to DisplayPort cable. How can I get 2560x1440?
    When I run recovery mode, then I get the full 2560x1440 pixels. But when I boot back to 10.9.2, then I can only choose a maximum of 1080p.

    After some hours I found a solution...
    But let me vent a little bit first: My MacBook Air, which I have not yet upgraded to Mavericks, is able to drive the AOC display through DisplayPort at full resolution without a problem.
    Even an older lenovo Notebook with Windows 7 immediatelly used the intended resolution when hooking up the 27" screen. Windows 7 outplaying Mavericks. Oh boy...
    So it seems, that Mavericks introduced some "improvement" that limitd "unknown" displays to 1080p...
    By the way: Clearing PRAM didn't resolve my issue. Neither did holding down the Option key when klicking in the "Scaled" button in the screen resolution area of the system preferences for my screen.
    Anyway: I found out that I can use the plist file for a DELL 27" screen, which google found for me, copy this to /System/Library/Displays/Overrides and then rename the folder and file to match the ID I got back from ioreg.
    Obviously one has to be careful when mixing hardware data in this way. But since a modern screen will simply refuse to be driven with a signal that is out of spec, and since there are not too many different 27" pannels with 2560x1440 out there these days, this felt like a pretty safe thing to do... Your mileage may vary though!
    Unfortunately I don't have a plist editor installed. Thus I can only look at the XML contained in the plist file. With the plist editor from Mac (-> dev tools) it should be possible to edit available resolutions directly (in hex).

  • How do i run an external monitor with my macbook and change settings so that when i close the lid the signal to the monitor is not lost and i can continue using the mac with a mouse and a wireless keyboard?

    How do i run an external monitor with my macbook and change settings so that when i close the lid the signal to the monitor is not lost and i can continue using the mac with a mouse and a wireless keyboard?

    No, nothing will prevent the computer from going to sleep when you close its display except third-party hacks that are designed to do exactly that. I strongly advise against using any of those, as they may interfere with successful entry into clamshell mode (and they carry other downside risks as well). Just wait until the computer is asleep (with its sleep light pulsing), then press any key on the keyboard. It sounds as though your setup is working as it's designed to do.

Maybe you are looking for

  • Tape to DVD

    I have a family history VHS tape that was made in the 80's by relatives who have now died. Yesterday I transferred the tape (which was not great quality but contains otherwise irretrievable information) to DVD via my VHS/DVD recorder/player. I succes

  • Limit number of rows from wildcard expansion- DRG-51030

    We use CONTEXT iindex in 11g to search on a text DB column, "Name". This is used in a UI to show autosuggest list of 25 matching names. When the end user types an 'a' we want to show a list of the first 25 names that contain an 'a'. We hit the issue

  • DUPLICATE POST - DELETE/IGNORE

    DUPLICATE POST - DELETE/IGNORE Message was edited by: BallisticJack

  • Oracle 10 g documentation

    hi all I had downloaded the oracle 10 g Documentation. But when i try to search any thing in it in Search column i requires an internet connection. can i run it off line . please tell me that how can i use of line . specially the search option. regar

  • I can't open files after redownloading Adode Digital Editions

    I redownloaded Adobe Digital Editions after my laptop crashed and had to be restored to its out-of-box state. But now some of the acsm and pdf files I could open can't be opened anymore. I continually get an error message about failing to obtain the