Can we make jar file for simple j2se application

Hi..Can we make a jar file for simple j2se application so that it can be executed on any system like .exe file...

Read the JAR files section in Sun's Java tutorial.

Similar Messages

  • How can I make .jar files for applications?

    My jar program creates jar files but won't open the program when I double click them. I use the command:
    jar cvf *.jar filenames
    The jar file is created but won't execute. Can anyone tell me what i am doing wrong?
    Thanks
    Jiby

    Hello !
    Well, I had the same problem a week or two ago !
    First, in your *.java, don't use any package...I mean, don't do a package of your program (I guess there is a way to make it work with, but it would need a little bit more work...).
    Then, with the jar tools, use the command
    -jar cf jar_that_you_want_to_create.jar class-that_you_include_in_your_jar.class
    With that, a jar will be created, and when you will try to "run" it, it will say that it can not find the main class...
    You need a Manifest !
    Create a text file MyManifest.text, and write that in your text file :
    Main-Class: classname
    follow the same as i wrote above. leave a blank after colon and a blank line after the first line like above.
    then, well, use tha jar tool again:
    -jar umf MyManifest.txt jar-file-you-created.jar
    To "run" it, double click on it, or use the java tool:
    java -jar jar_you_created.jar
    Thanks to Phani, who helped me with that !!
    Splitsch

  • How to make jar file for this compilation method ?

    can any one tell me how to make jar file for this compilation
    D:\java\browser\IEInJava>javac -classpath jdic.jar;. IEInJava.java
    D:\java\browser\IEInJava>java -cp jdic.jar;. IEInJava
    *this is a compile code:-*
    D:\java\browser\IEInJava>javac -classpath jdic.jar;. IEInJava.java
    *and this is a run code:-*
    D:\java\browser\IEInJava>java -cp jdic.jar;. IEInJavanow how make JAR file ?

    Assuming IEInJava only uses classes inside the jdic jar, this is one way. D:\java\browser\IEInJava> jar cf yourjar.jar IEInJava.classThen to run it you would use D:\java\browser\IEInJava> java -cp jdic.jar;yourjar.jar IEInJavaAnother way would use the jar manifest file to specify the Main-Class and Class-Path.

  • How to make .jar file for a multiple class program

    I have a code for a chat room that contains two folders , one for Server and one for Client
    What I need is to create a jar file for the server and a jar file for the clients
    but here the first problem , I have a file that named (SocketMessengerConstants.class) that is located outside the two folders and is being read by the two projects .
    I mean the server uses it while running and the client uses it too .
    the second problem is : I don't know how to create a jar file at all !
    please tell me how to do it in detail
    Thank you

    ChuckBing wrote:[Packaging Programs in JAR Files|http://java.sun.com/docs/books/tutorial/deployment/jar/index.html]
    I tried to read this tutorials before I come here but I couldn't understand it
    can you please tell me a specific steps to follow instead of the explaining .. because I understand the explanation but I can't apply it

  • From Where can i download  Jar Files for creation of adapter Module.

    From Where can i download these Jar Files.
    aii_af_mp.jar à the interface Module
    aii_af_ms_api.jar  à Dealing with payload and attachment
    aii_af_trace.jar à Writing Trace
    aii_af_svc.jar à Adapter Services
    aii_af_cpa.jar à Reading Channel Entries
    aii_af_ms_spi.jar
    aii_af_cci.jar 
    for creation of adapter Module.

    As k you basisn team,they will provided it.
    usually these jars files available in server, in usr.repositoy folder,if you have server level access then you can copy it else contact your basis team.
    or you can download it from service market place.
    Regards,
    Raj

  • How to make htm-file for simple toolbar command?

    Hi
    I am actually tryin to make my own toolbar with commands for Adobe Contribute CS5. A very nice companion for DW sites for endusers to edit the site.
    Creatin toolbars for Contribute and Dreamweaver is the same thats why writig here.
    I have managed to make a toolbar and managed to copy existing commands, like browsing backward and browsing forward, in it, but I have not been able to make my own commands  because I have not been able to figure out how to write the correct javascript into the header of the htm-file.
    I have a set of small predefined html-tables, 15 of them, that user can copypaste into his template generated page, when editing, in order to have some layout order without knowing much of editing with Contribute editor.
    Now, I desperately want to have 15 descriptive buttons in my own toolbar appear when in editing mode. User can choose and click the one he needs, a title1-unit, a title2 unit, a 1-column text unit, 2-column text unit etc. The correctly formatted table enhanced with css-properties appear there where the cursor was positioned. No more copying from one page and pasting to another - much much better this way!
    All I need is htm-file for each of those 15 units. I have not been able to find an example that I could modify.
    Can anyone help. A button (a command) klicked on a toolbar should position the htmltable there where the cursor is - nothing else.
    Htm-files should be positioned here, I think:
    C:\Program Files\Adobe\Adobe Contribute CS5\App\Configuration\Toolbars\MM
    Or is C:\Program Files\Adobe\Adobe Contribute CS5\App\Configuration\Objects\ better?
    Eagerly waiting an answer,
    Kari
    Here is an example of a 1-column unit. All 15 of my units are like this.
    <table border="0" cellpadding="0" cellspacing="0" class="unit1 spacebelow" name="text_1col">
         <tr>
              <td class="txttd unit_pad1_left unit_pad1_right bkgr_check3">
                   <p>Text here</p>
              </td>
              </tr>
    </table>

    This Script works here. Get you the error, when you save or checks the syntax?
    When you use in AppleScript the entry with administrator privileges, is sudo optional. This says only, if everyone can use the sudo command inside of the 5 minutes limit without to write the password again or not.
    The Syntax do shell script "sudo chmod 755 "private/var/spool/cups" password "***" doesn´t work, because you need the entry with administrator privileges for the execution as privileged user.

  • Problem while creating JAR file for my swing application

    Hi...
    Using my swings application I am trying to Run different software�s .
    My program is Running fine from command prompt. If I create JAR file
    It is giving error like �Failed to load Main-Class manifest attribute from .jar�
    Can anybody help me to creating JAR file
    Thanks in advance
    Cheers
    Mallik

    hi,
    User following command
    jar-cmf textfile_name.txt Jarfile_name *
    here you have to make manifest file
    and making jar file you have reach there by command promt
    and manifest file have some constraint also as well as format
    format are
    Manifest-Version: 1.0
    Class-path: jar file name which are using in app separed by space
    Created-By: 1.5.0 (Sun Microsystems Inc.)
    Main-Class: Main class name
    and end of file is not have carriage return

  • .jar file for wls client application

    Is there a .jar file include files when client app needs at runtime

    You need weblogic jar file and if its ejb client application you might need client
    file that can be produced by ejbc.
    S
    "Wei Li" <[email protected]> wrote:
    >
    Is there a .jar file include files when client app needs at runtime

  • Where i can find the .jar file for com.borland.jbcl package

    when i rebuilt my application i met this error message
    package com.borland.jbcl.layout.XYLayout does not exist
    please help
    thanks

    Hi,
    Check out the "download" link at the following address.
    http://cougaar.org/cgi-bin/viewcvs.cgi/jars/lib/jbcl.jar?cvsroot=core
    Hope that help,
    Jack

  • Virus scan failed Error on deploying a web application having a jar file for calling the applet on the jsp page

    Hi,
    I have an applet application that i want to deploy on the Oracle cloud.
    So i have created a jar file for the applet application and i am using this jar to call the applet on a jsp page.
    But when i am delpoying my application on the java cloud, its giving me the below error:
    2014-10-28 03:16:41 CDT: Starting action "Virus Scan"
    2014-10-28 03:16:41 CDT: Virus Scan started
    2014-10-28 03:16:49 CDT: ----------------------------------------------------------------------
    2014-10-28 03:16:49 CDT: File Scanned: "Application7.ear".
    2014-10-28 03:16:49 CDT: File Size: "106698122".
    2014-10-28 03:16:49 CDT: File Status: "INFECTED".
    2014-10-28 03:16:49 CDT: ----------------------------------------------------------------------
    2014-10-28 03:16:49 CDT: Virus scan failed.
    2014-10-28 03:16:49 CDT: "Virus Scan" complete: status FAILED
    Can't we deploy any application having applet or swing component's onto the cloud?
    Or do we need to request for any extra permissions for the same?
    Thanks,
    Manoj

    I don't see applets mentioned in the supported features nor in the unsupported features so not sure if they are supported you would likely need to contact the operations team to confirm.
    Jani Rautiainen
    Fusion Applications Developer Relations
    https://blogs.oracle.com/fadevrel/

  • Can I include dlls in a jar file for deployment?

    I have a set of dll's I need to deploy (some kind of database driver needed along with my java application) in a client/server situation. Instead of copying these dll's to the client's system32 folder on windows, can I simply include these dll's in the jar file containing my java applications?

    No it was just to make everything cleaner. But if I have to take them outside of the jar file, then like you say there's no benefit in putting them in there in the first place.
    As for having the dll's in the same directory or a sub directory, how can I load them then? Using the function System.loadLibrary?

  • How can i make a file a .jar again?

    Ive opened a minecraft.jar with Archive Utillity so i can change pictures but ow can i make a file a .jar again?

    You have not said what your target size is nor how many photos you have or how large on screen. Nor what version of Pages you are using. Nor whether it is just for looking at on screen or you require a good print.
    Reducing file size is a combination of things that can be done with no loss of quality:
    1. Crop and reduce resolution of images in a 3rd party application, Preview will do.
    and those that will reduce quality
    2. Menu > File > Reduce File Size
    3. Menu > Share > Export > PDF > Good (Good is not very good unfortunately)
    Use vector (drawing) pdfs in place of bitmap (photo) images can save considerable size. Preparing photos in other programs also allows you to control the image quality of jpegs and tricks like slightly blurring them prior to saving.
    Pages is not very efficient in this regard and there are limits to what you can do. Lots of images, covering a lot of the page does add up to a bigger file whatever you do.
    Peter

  • How to make jar files availabe for deployed EJBs

    Hi,
    I'm interested on how to make jar files availabe for deployed EJBs.
    My EJB is packed in an ear. It uses a util jar. I now just add the jar to the
    classpath, but I think that shouldn't be the way. Is there somthing in the admin
    console to make jars available or do I have to insert it in the ear file? And
    if so, where do I hve to place it?
    Thanks
    Claudia

    Put the util.jar in the ear with your ejb jars - at the same level (i.e. in
    the root) - but do not include them in the manifest.xml.
    Also each ejb jar that refers to util.jar must have util.jar on its internal
    classpath in the manifest.
    "Claudia" <[email protected]> wrote in message
    news:3d537db5$[email protected]..
    >
    Hi,
    I'm interested on how to make jar files availabe for deployed EJBs.
    My EJB is packed in an ear. It uses a util jar. I now just add the jar tothe
    classpath, but I think that shouldn't be the way. Is there somthing in theadmin
    console to make jars available or do I have to insert it in the ear file?And
    if so, where do I hve to place it?
    Thanks
    Claudia

  • Can anybody provide type 4 jar file for oracle 9i + jdk 1.5

    Hello,
    I want to connect my java application(jdk 1.5) to oracle.Can any body provide the jar file for that one and whre I want to put that jar file.Please send me one sample code for jdbc connection to oracle for calling a stored procedure in oracle.
    Bipin.V

    Wouldn't it be easier to google on e.g. oracle jdbc download?
    http://www.oracle.com/technology/software/tech/java/sqlj_jdbc/index.html
    Kaj

  • Where can I find the jar file for File Transfer Service API

    Hi all ,
       I wish to use the File Transfer Service API in my application . Could anyone please tell me as to where I could find these class files ??
    <b>import com.sap.engine.services.file.RemoteFile;
    import com.sap.engine.services.file.FileTransfer;
    import com.sap.engine.services.deploy.DeployService;
    import com.sap.engine.services.deploy.container.WarningException;</b>
    Thanks in advance ,
         Tahzeeb

    Hi,
    you can find these jar files in the installation directory of NWDS:
    ...SAPJDTeclipsepluginscom.sap.tc.apcompSAP-JEEDCssap.comcom.sap.engine.deploy.online_compgendefaultpublicdefaultlibjavasapj2eenginedeploy.jar
    ...SAPJDTeclipsepluginscom.sap.tc.apcompSAP-JEEDCssap.comfile_compgendefaultpublicdefaultlibjavafile.jar
    Regards
    Sebastian

Maybe you are looking for

  • Gaming resolution

    I'm trying to play Splinter Cell Mac Version on my G5 but my monitor keeps on coming up with the out of frequency message. What resolution do I need to set my monitor to so I can play. I'm running at 1280x960 on a 17" LCD.

  • Xp20:format-dateTime method in BPEL 11g

    I am doing a date conversion as xp20:format-dateTime('2007-10-07','YYYYMMDD') and storing in a String variable - givenDateConverted but the result is as below <givenDateConverted >YYYYMMDD</givenDateConverted> My original requirement is to compare th

  • ROLAP skip level dimension support - CWM2?

    Dear all We have a client with an interesting problem. I was wondering if the group could offer any feedback on this design question, where we think it involves a concept called 'skip levels'. The client is using Oracle 9.0.2 with their data mart cub

  • Keynote news ticker?

    Can i make a "news ticker" like object in keynote, like the scrolling text at the bottom of news programs?

  • Camera Profile Beta - will it port?

    First, thank you very much to Adobe for creating these new camera profiles per: http://labs.adobe.com/wiki/index.php/DNG_Profiles#Camera_Profiles_and_DNG_Profile_Editor For the Fuji S5 and Nikon D80 this makes a major difference. So, here's the quest