Re: How do you specify an external jar and library when executing from a ja

When you specify java -jar the -classpath argument is ignored and the jar's manifest file is used - see http://java.sun.com/docs/books/tutorial/deployment/jar/ .

OK you know I read that somewhere and then totally forgot about it.
I know this isn't the place to ask but I've had limited success with asking eclipse questions on their forums.
Does anyone know how to export a jar file with the correct manifest from eclipse? My application works fine in eclipse but doesn't export a usable jar. To fix this I have to unjar the file, add the manifest text and rejar it.
Thanks,
Jim.

Similar Messages

  • How do you make a movieclip display and play when click on a button

    I'm looking to have a movie clip pop up, play itself after a user clicks on a flash navigation button.
    (something like this???)
    message_btn.addEventListener(MouseEvent.CLICK, goMessage1);
    function goMessage1(evt:MouseEvent):void
        ???(play message movie clip here)???;

    How you code that depends a bit on how you design the movieclip.  You could make the movieclip have an empty first frame that it is stop()-ed at, and tell it to play() in the event handler function.  Or you could have the movie's visible property  initially set to false and stop()-ed at frame 1 and have the event handler set the visible property to true and tell the movieclip to play();
    The key is to have a plan where the movieclip is waiting to play and has an instance name assigned to it that you can use to command it to play when you want it to.

  • HT1689 how do you change your security questions and answers when you've forgotten them?

    baldy

    See this previous discussion:
    recover answers to security questions: Apple Support Communities
    and maybe here:
    Can I change the answers to the security questions for my Apple ID?
    Yes. You can change the answers to the security questions provided when you originally signed up for your Apple ID. Go to My Apple ID and click Manage your account.

  • How do you uninstall the wireless service and lenovo battery indicator from the task bar.

    Was wondering if there is a way to remove them from the taskbar. Initially I had just the battery indicator and then I downloaded all the lenovo updates (for bios, etc.) and got the wireless service indicator too. They seem kind of redundant to me, as windows 7 already has their own on the task bar and they're just taking up additional space.
    I'd atleast like to get rid of the wireless service.
    Will this effect anything? Are they that important?
    LENOVO 8BET54WW (1.34), 11/2/2011 - W520 Model 427639U - Windows 7 - 6.1.7601 Service Pace 1 Build 7601 - intel core i7-2820QM CPU @ 2.3ghz, 2310 mhz 4 cores - 16gb Memory

    Was wondering if there is a way to remove them from the taskbar. Initially I had just the battery indicator and then I downloaded all the lenovo updates (for bios, etc.) and got the wireless service indicator too. They seem kind of redundant to me, as windows 7 already has their own on the task bar and they're just taking up additional space. 
    Right click on the Lenovo battery gauge in the taskbar, click "Launch Power Manager", click Options, clear "Show Power Manager Gauge in taskbar" check box.  If Options tab is not available, switch to Advanced mode (upper right corner of Power Manager).
    Don't recall specifics for Lenovo network icon, but is probably just as simple.  Would be better (IMHO) to get rid of Access Connections altogether.
    Removing the icons will have no affect on anything, except your piece of mind from removing these ugly and redundant symbols of bloatware.  They are NOT important.
    W520 | FHD | i7-2720QM | 8GB RAM | nVidia Quadro 1000M | Intel 510 120GB SSD | Seagate 7200rpm 500GB HDD
    T510 | 1366x768 | [email protected] | 8GB RAM | nVidia NVS 3100M | Seagate 7200rpm 500GB HDD
    T61p | 1920x1200 | [email protected] | 4gb RAM | nVidia Quadro FX 570M | Hitachi 320GB HDD | (broken frame, now a file server)

  • How do I specify an external viewer for animation?

    I occasionally receive PDF files that have accompanying animations (.avi, etc) that Adobe acrobat reader 9.4.1 expects to play using an external viewer.
    On one of my computers (Linux, KDE), it launches xine.  On another (also Linux, KDE), it launches noatun.
    How do I specify which external viewer it should launch?

    This is handled through file associations defined in the OS. Adobe Reader is simply passing the file off to the OS.
    In your file manager/desktop, find a plain AVI file, right click on it to get the contextual menu. You should be able to set your preferred associated program from there.

  • How do I deploy an external JAR file

    Hello,
    How do I deploy an external JAR file?
    I am grateful for every hint.

    Hi Manuel,
      If you read my blog mentioned in the beginning of the thread, you will note that such solution is not supported in our engine due to number of reasons.
      Please, read the blog and use application library shared among these two applications. You will achieve the same effect. Please note that the using application will need run and deploy-time dependencies to the shared library.
      You should not add files to any of the folders manually or manipulate engine's classpath in such situations.
    Best Regards,
    Georgi

  • How do you move a single album, and not the whole library, in iPhoto to an external hard drive?

    How do you move a single album, and not the whole library, in iPhoto to an external hard drive?

    File -> Export to a folder and copy it over.
    That will give you a folder with the images. There is no way to move an album outside of iPhoto. You would need to have a library containing it.
    Regards
    TD

  • I have lost my external drive on desk top.  How do you remount the external drive

    I have lost my external drive from iMac desk top.  How do you remount the external drive?
    WindyCityNorth

    Kappy Thanks for help..  I had already tried the Disk Utility but external drive did not show.  What worked was to shut down every thing and shut off power to all.  Disconnect power to the external drive.  Connected power to computer and then restarted the computer.  After the computer was up and running, I reconnected power to external drive and then turn it on.  At this point the external drive returned to my desk top

  • HT201250 How do you add an external Hard drive to time machine and share on network?

    How do you add an external Hard drive to time capsule and share it on local network?
    Lee

    Ensure it's formatted as Mac OS Extended, FAT16, or FAT32, connect it to a self-powered hub, and plug it into the Time Capsule's USB port. If the drive is Ethernet and not USB, ignore everything else and just plug it in.
    (71787)

  • How do you specify what format you want the song to download in?

    How do you specify what format you want the song to download in?

    In preferences set up your import settings, then right click on the tracks you need in a different format and use Create < Format> Version. New copies will be created in the target format.
    tt2

  • How do you specify a line number with getline() (c++)

    How do you specify which line for getline() to read with c++ similiar to how awk uses $1, $2, $3 , etc etc...
    Example:(Ignore the underscores)
    Line1 Line2
    10____10
    20____20
    30____30
    40____40
    if I were making a program to remove 10 on the first line and 20 on the second line how would I tell getline which line to read
    Example source code:
    #include <cstdio>
    #include <fstream>
    #include <string>
    #include <iostream>
    using namespace std;
    int main()
    string line;
    string line2;
    ifstream in("/Users/lundquisted/Desktop/infile.txt");
    ofstream out("/Users/lundquisted/Desktop/outfile.txt");
    while( getline(in,line) )
    if(line != "10")
    out << line << endl;
    while (getline(in,line2) )
    if(line2 != "20")
    out << line2 << endl;
    in.close();
    out.close();
    remove("/Users/lundquisted/Desktop/infile.txt");
    rename("/Users/lundquisted/Desktop/outfile.txt","/Users/lundquisted/Desktop/inf ile.txt");
    return 0;
    }

    Eric Lundquist wrote:
    store the output of a system() command within a c++ program to a string and/or variable
    A number of apps call Unix utilities and capture both stdout and stderr, typically for viewing in a log window, but for other uses as well. Xcode, for example, starts up gcc and does various things with the text that gcc might otherwise print in a Terminal window. Most apps that rely on Unix commands that way don't use "system()", which is a rather crude way of launching utilities that leaves the parent program with very little control. Usually, the best way to manage helper utils from a Cocoa app is by using NSTask and NSPipe. If you spend some time with the two following pages, you'll learn how to do almost anything you want with command line utils from inside a Cocoa app:
    [http://www.cocoadevcentral.com/articles/000025.php]
    [http://macosx.com/forums/archive/t-3927.html]
    The first link goes to a great tutorial on using NSTask. Capturing stdout and stderr are only covered briefly towards the end, however. Note the last comment explaining why "system()" is a bad idea.
    The second link goes to a forum thread. Scroll down to the code posted by "blb" for some very clear examples of launching with NSTask and reading the output with NSPipe.
    If you really want to use a shell command, you could give NSTask a command like ' +bash -c "ls -lt | grep drwx"+ ' (see how setArguments: is used in the tutorial).
    If you just want to do something cheap and dirty with "system()" so you can see some awk output while you're learning how to do things the right way, I guess you could do something like this:
    system(" cat ~/random.txt | awk '{print $2}' > MyFile.txt");
    NSString *myString = [NSString stringWithContentsOfFile:@"MyFile.txt"
    encoding:NSUTF8StringEncoding error:nil];
    Of course you can just read MyFile.txt into cin if you're not using Cocoa.
    - Ray

  • I have an external hardrive for MAC, I needed to save something from my work computer so I can pass it on to my MAC, it requiered me to re-format my external HD and now when I connected to my MAC I only have "read only rights". How do I fix it?

    I have an external hardrive for MAC, I needed to save something from my work computer so I can pass it on to my MAC, it requiered me to re-format my external HD and now when I connected to my MAC I only have "read only rights". How do I fix it? I run my Itnues from this external and now my library is gone. Luckily I have it saved somewhere else, which is not a problem, but I won't be able to write to this HD for right now. I can't see an option to give those permission back.

    cptjuanjvarona wrote:
    I have an external hardrive for MAC, I needed to save something from my work computer so I can pass it on to my MAC, it requiered me to re-format my external HD and now when I connected to my MAC I only have "read only rights". How do I fix it?...
    Unless what you have to transfer is enormous, skip the external HD altogether and use a USB flash drive; you can get them with capacities to 128GB. Format the flash drive as FAT32 or ExFAT as LowLuster suggests so it can be read and written to on both PC's and your Mac.

  • How can I make an external link (to a different folder) from the main menu?

    How can I make an external link (to a different folder) from the main menu?

    If the folder is outside the Muse page, you will have to insert manual HTML to define a more complex URL like e.g. ../_stuff for going one level up and then into a folder called "_stuff" The deeper you are in the hierarchy, the more ../ you will have to add to climb up.
    Mylenium

  • How do I put an external display to sleep when I am using my MacBook Air for presentation?

    How do I put an external display to sleep when I am using my MacBook Air for presentation? I do not want to go to the projector just to turn it off and turn on again after a while? Is there a keyboard shortcut for that?

    I want to be able to sleep the external display and at the same time do things in the MacBook.( This feature is useful for me so that I can prepare some things and so that my audience will not see what I am about to show them.)
    Is there a feature for Mountain Lion?

  • How do you delete duplicate songs in your library without having to delete each song individually??

    How do you delete duplicate songs in your library without having to delete each song individually?

    mauijiminar wrote:
    Go to iTunes, select view and click show duplicates. Hold control and A ( select all) and then delete.
    Not a good idea! The "show duplicates" feature shows "all" duplicate tracks, but you only want to delete the "extra" copies, not the "originals".
    I've written a script called DeDuper which can help remove unwanted duplicates. See this  thread for background, including how to delete the extra tracks manually if you prefer.
    tt2

Maybe you are looking for