.class to exe

can i convert java class file to windows executable file without using the readymade softwares availabe in the market

can i convert java class file to windows executable
file without using the readymade softwares availabe
in the marketIf you need a windows executable, why can't you use a readymade software, like jsmooth, it's open source/GPL, don't cost you anything. I don't think that there's straightforward way to create .exe file from .class file.
by the way, this forum is for j2me (mobile) discussion.
kari-matti

Similar Messages

  • Converrsion of .class to exe file

    i googled the above problem. in one of the forms i got the information. it instructed me to use javaw [filename] to acheive the same. but when i use javaw [ file name] it comes with the msg "cannot find main class. program will exit".
    I just want to create an .exe file so that when any one double clicks on the .exe file, this bring up the application.
    thanx in advance
    regrads
    naveen

    You have 2 options:
    you can make an executable JAR file and require you have the JRE/JDK installed or do a search in the forums and get a hold of one of the dozen or so threads telling about the host of products that make EXE's out of Java and the pro's and con's therein.
    Do the search, we don't need to regurgitate the same thing again because you didn't search.

  • Execute Class Files (.exe)

    Hi!
    How could I change a java program into a execute program ( .exe) under Windows NT?
    Thanks

    Look into the jar tool.
    http://developer.java.sun.com/developer/onlineTraining/Programming/BasicJava2/jar.html#jar

  • Jar or class to .exe on Windows

    Hello everyone, it is just a simple question.
    Does any of you knows of a good tool or a way to transform a program developed in Java (either
    if there are packages and the thing) to a Windows executable file (.exe)?
    Thanks in advance.

    I've looked throughout the forum but I've only found
    how to call an executable from within the java code,
    but not convert it into an exe.
    And about googling it, I found few (maybe not using
    the correct keywords, any suggestion?), and they
    don't quite work well, so, just asking if any of you
    have had success with one and, what is the name of
    it.
    Thx.can't have looked very far, then. the definitive answer to this question has been posted several times, quite recently
    the real question, though, should be "do I want to bind my nice portable java code to a particular platform?"

  • Making an exe from a bunch of classes

    Hello all
    Is it possible to make an exe from a bundle of classes? e.g. I have a couple of java classes one of which contains a main() function. I want to create an exe file with a simple GUI that accepts command line arguments and runs the program. If anyone can help me, please do.
    Thanks
    Gurpreet Singh

    http://www.google.com/search?hl=en&q=class+files+to+exe&btnG=Google+Search
    http://onesearch.sun.com/search/onesearch/index.jsp?qt=class+to+exe&subCat=&site=dev&dftab=&chooseCat=javaall&col=developer-forums

  • Unable to run an exe file from a Servlet

    I am not able to run a Servlet that calls an exe file using the following code. trial.exe is was built from a C program and it is simply a program that creates a text file with some content. I am using Tomcat 6.0 and JDK 1.5 on a Windows XP.
    {color:#000080}try
    Runtime rt=Runtime.getRuntime();
    String[] command = {"C://Tomcat 6.0//webapps//ROOT//WEB-INF//classes//trial.exe"};
    {color}
    {color:#000080}
    Process p = Runtime.getRuntime().exec(command);
    p.waitFor();
    catch(Throwable t)
    // System.out.print(t.getMessage());
    }{color}
    Before running the code on Tomcat I've compiled the code above in a simple java programe and it executed without any problem.
    Then I compiled the code within a servlet. No luck. Then I treid the following options:
    Executed the Tomcat service under the context of a user by specifying a user(Log On option) for the Tomcat service.
    Then with Local System Account, selecting “Allow service to interact with desktop”.
    this time also, no luck. Can somebody help me on this please ?
    BJJ

    For clarity I am rewriting the last sentences here:
    Then I compiled the above code within a servlet successfully and invoked the servlet from a browser with and without the following settings of Tomcat 6.0.
    1. Executed the Tomcat service under the context of a user by specifying a user (Log On option) for the Tomcat service.
    2. Then with Local System Account, selecting �Allow service to interact with desktop�.
    I was not succeeded with any of the methods mentioned above.

  • How to create smaller .exe file use JBuilder7

    I am currently using JB7(EE), which can create native executable file for me. But I found it so foolish that add so many unneed classes to .exe(As I can use WinRar open it, but cannot change it).
    Does anyone know how to reduce the .exe?
    ps: As I use castor, so I had to include castor class in it, but I really don't want to add all of these to it.

    In the Wizar you employ to make the native executable,
    in the second step the Wizard ask you what to do with
    the libraries you have employed in the proyect,
    include all them include only the classes and
    resources nedded, or not include. This way you'll be
    able to control what is in you .exe file.
    AbrahamYes, I had tried it, and tried every possible combination/permutation of the four choice.
    But still bigger than it can be.
    For example: I used castor.xml library, but JBuilder include all castor include xml parser, html parser, xhtml parser, etc.
    As castor.xml --> castor.xxx(I cannot remember its name) --> castor.html-->...
    So JB7 maybe confused by the complex deps.
    So JB7 include ALL in my exe fiel.
    It may be impossible to create smaller .exe file with normal way.
    So anyone know any other way to create .exe file with the .jar file?
    As I can change the content of .jar, but cannot to .exe.
    thx for continous reply

  • Help Needed - Executing a .exe in a JAR

    Hi,
    I am stuck with a problem...
    I have a jar file which has an applet class, a .exe file and a .txt file.
    I want the applet to call the exe which will use the .txt and produce two more .txt files(inside the jar)..
    Is it possible?
    Thanks,
    Bharath

    I want to run my applet from the web. But the applet should call a exe (which takes in a txt as a input) and generate a couple of txt's.....
    To make my applet execute the .exe i had to make it into a signed jar....so now how do i do it without putting the .exe also into the jar?
    Is there any other way?
    Thanks
    Bharath

  • Compile Java to exe

    Hello everybody!
    Does anyone of you know, how to compile a java file to a single windows executable (*.exe)? Is that possible?
    What programes do I need, and what is needed on the computer on which to run the *.exe ?
    CU
    Netzmeister2k

    Plz try ZERO G Install Anywhere program ... You can download it from http:\\www.zerog.com.... I think now a free version is available for personal use ... other wise you have to purchase it .... You can download it from the site ..... In my opinion , I used zerog instally anywhere software ... it is best for java classes to exe ..... You can make exe with JVM and with out JVM .... it depends you ... I recommend this software ........Bye

  • How to create Exe?

    I have java applications that will be used on Windows. I don't want to use bat file to start them. So I need some tool that will convert java classes to native. Can somebody tells me what to do?
    Nencho Nikolov

    Nencho,
    If your idea is just to use exe to start your java application you do not need to convert your classes to Exe. The only you need is simple C launcher that loads Java Virtual Machine as DLL and pass on it main class, class path, system properties and etc. There are a lot of examples in the internet doing this.
    If you don't have time to study this topic then my advice is to see a tool available at http://www.geocities.com/j2exe. It is designed to make exe files. I think that it is very simple to use and at the same time will provide you with all that you need - exe file with its own icon. Works perfectly.
    Alexi

  • Passing values and calling other classes?

    Hello all.
    I have 2 classes(separate .java files). One is a login class and the other is the actual program. Login class(eventually exe file) should open the other class and pass the login parameters if you know what I mean. Is this possible, or do the 2 classes need to be part of one file?
    Thanks alot
    Milan D

    Login class can be another class in another file
    wht u have to do is to make an instance of login class in the class u want to use that class
    like login lg = new Login();
    and call method of login class
    lg.setUser(username);
    where setUser(String user); is a method of login class
    this way u can pass the parameters to login class
    i hope this might be helpful
    regards
    Moazzam

  • Executing an file.exe from a jar file?

    Does anyone know how to execute an *.exe file from jar file?
    I have two files that I want to execute in one java.class, Monview.exe and Moninit.exe. Both are stored in the same jar file as the class called link.class.
    This is my code to run one of the files from the hard drive
    String []cmd={"c:\\monview.exe"};
    try
    Process pr = Runtime.getRuntime().exec(cmd);
    StringBuffer buf = new StringBuffer();
    InputStream istr = pr.getInputStream();
    BufferedReader br = new BufferedReader(new InputStreamReader(istr));
    String str;
    while ((str = br.readLine()) != null) {      
                             buf.append(str);
    try {       
    pr.waitFor();
    } catch (InterruptedException e) { }
         if (pr.exitValue() != 0) {      
         br.close();
    catch (IOException e){}
    It works when i place both .exe on the local host harddrive but when I place it in the jar file nothing happens. Could anyone help me please on why does this happen and how I can fix it? Or on how to get the link.class code to extract it from the jar file and place it on the system directory and delete it from the system directory, without it knowing where the jar file comes from?

    Hello,
    If I am not mistaken, by including the JAR file in the CLASSPATH (specifying the absolute path), or after the -classpath option after the java command (java -classpath jar_archive main_class), the system will find both files in the JAR archive.
    Hope this helps!

  • How to protect read-only data in Swing app from tampering?

    First off I am new to cryptography and trying to find the best approach for a problem.
    We have a Swing application that uses xml-based template files to display complex forms and validate data entry. Based on the size and complexity of the forms it was deemed better to have a distributed stand-alone application instead of a web-based solution. However, we want to ensure users do not tamper with the template rules in order to pass the validation checks. All of the xml-based template files are distributed within a single jar file.
    The first thought was to build a list of check-sums of the template files and to compare the template to the approariate check-sum from within the list before loading a template. This would prevent the more casual user from tampering with the file but not someone knowledgeable in check-sum who could recalculate the CRC and update the list after making changes.
    Another thought was to use a private key to encrypt the CRC list before distribution and a public key to decrypt it during execution with the keys maintained in a keystore. However, once again, an adventurous user could weed through the obfuscated code to determine the password to the keystore, create a new keystore with the same password and use its private key to regenerate the CRC list from altered templates.
    I feel like there must be a simpler approach that will provide a bullet prove implementation. Any suggestions?

    I think you have to re-think your design.
    Whether you use Java, C#,C or C++ a hacker can look through the binary (class file, exe file etc) and after working out what is happening he can modify your code.
    It is my opinion that your best bet is to use client/server but even with that you cannot keep any private data or code on the client.
    You will still have to think about 'man-in-the-middle' and 'spoof site' attacks.

  • SCCM 2012 R2 reporting error: "The DefaultValue expression for the report parameter 'UserTokenSIDs' contains an error: A specified logon session does not exist. It may already have been terminated. (rsRuntimeErrorInExpression)"

    Hi,
    I have two SCCM environments under same active directory domain and one service account have been used for SCCM configurations on both the environments (QA and PRODUCTION). I am facing similar error as mentioned above while trying to fetch reports on
    PRODUCTION site, but the QA site is working fine, though same service account have been used for configuring both. While looking at the reportserverservice_<date> log on my Production DB server i see the following error
    "processing!ReportServer_0-3!2124!01/02/2015-09:09:30:: e ERROR: Throwing Microsoft.ReportingServices.ReportProcessing.ProcessingAbortedException: , Microsoft.ReportingServices.ReportProcessing.ProcessingAbortedException: An error has occurred during
    report processing. ---> Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Cannot read the next data row for the dataset DataSet1. ---> System.Data.SqlClient.SqlException: Conversion failed when converting the nvarchar value 'Override
    Default' to data type int."
    My DB and SCCM primary site are different and the reorting services point is installed on remote DB server. Please help me resolving the issue.
    Troubleshooting performed:
    1.Disabled the registry key 'EnableRbacReporting' from HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\SMS\SRSRP to 0 and then restarted SSRS service and the reporting worked for some minutes after that the registry key reverted back to 1 automatically and
    reporting started throwing errors again.
    2. Checked with the permissions on DB whether or not 'sysadmin' role is assigned to the SCCM service account.
    3. re-registered the SQL management Provider WMI class.
    mofcomp.exe “C:\Program Files (x86)\Microsoft SQL Server\110\Shared\sqlmgmproviderxpsp2up.mof”

    Hi All,
    Finally found exact solution to the reporting error.
    Error: while launching SCCM reports (both from Console and web based) an unexpected error occured with error message as "The DefaultValue expression for the report parameter ‘UserTokenSIDs’ contains an error: A specified logon session does not exist.
    It may already have been terminated. (rsRuntimeErrorInExpression)"
    Solution: This is password replication issue for the domain account used to configure reporting services point in SCCM. If your SQL SSRS reporting services instance and databse runs with local default account whereas the reporting services point on SCCM
    primary site is configured with domain account, (As in My case) you need to perform the following in order to get rid of the error.
    Launch 'Reporting Services Configuration Manager' from the SQL SSRS box(either Local or Remote), Connect to Report Server Instance->Go to 'Execution Account' tab->Specify the 'Execution Account' as domain account and password which is used to configure
    Reporting Services Point in SCCM Primary Site, and then click apply.
    Now Lauch the report either way (Web based or from Console), the error will disappear and all your default reports will execute perfectly as before.

  • Java gits -- look here please

    How do I convert a .class file to an .exe file using the Date class which extends an interface that doesn't have a classpath?

    What are you going on about? It makes perfect sense to a git.But not if you understand Java.
    How do I convert a .class file to an .exe file There are many examples on google.
    http://www.google.co.uk/search?num=20&hl=en&ie=UTF-8&c2coff=1&q=exe+java&btnG=Search&meta=
    using the Date class The Date class is a standard class so is always available.
    which extends an interface that doesn't have a classpath?Interfaces do not define a classpath. Thus this is always the case.
    When you convert from .class to .exe you only need to have all your classes/interfaces at this point. Once it is a .exe none of these are required.

Maybe you are looking for

  • How can i get rid of In-Box:don't want it - won't use it - don't like it and most unprofessional to take-over a past wonderful site.

    got home from out of town and when computer went on up comes this In-Box thing. I did not order it, Don't Want it and WILL NOT USE IT and it has a lousy "google finder" in other words IT STINKS. I want to get rid of it and have Firefox open with Goog

  • What is the video quality loss going Mac to PC vs Mac to Mac?

    Here's the deal, my wife is in the hospital and forced to miss her daughters wedding. I'm trying to sort out an iChat from Louisiana to Texas so she can watch the wedding live and ideally let her daughter see her mom during the ceremony. I've not bee

  • Validation on data and time format

    Hi In a flat file a date and time fill in but user.  And the data and time format should always be fill in with the format <DDMMYYYY> <HHMMSS> is there a FM which check whether user has put the wrong date format such as <YYYYMMDD> or <MMDDYYYY> inste

  • How to capture content activity log from DMP?

    Hi There, I try to implement content activity log from DMP. The information that I want to get are DMP IP, Conent File Name (video or jpg file), open date/time. The only way that I can do is sending http command direct to DMP (http.file via port 7777

  • Executing an HTTP Request in ABAP Code

    Hi, I have to write an ABAP program to check VAT numbers before making any VAT declaration. SAP checks the logic of the number, however it does not check if a VAT number is still valid for that company. The European Commission has a website (http://e