How to Use Windows XP theme in Java

How to Use Windows XP theme in Java.
I am an developing application which L&F should be like Windows XP.
Because I am going use this application in different OS.
Which LookAndFeel I have to use it

try this in main:
try {UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());}
catch (Exception exc) {System.err.println("Eroare la incarcarea look & feel" + exc);}

Similar Messages

  • How to use the TCP/IP in Java?Thanks!

    How to use the TCP/IP in Java?Thanks!

    Look at the java.net package, more specifically to classes ServerSocket (The server TPC conection) and Socket (the client TCP conection)
    Abraham

  • How to use HTML Tags in webdynpro java

    Hi,
         Can any body tell me how to use HTML Tags in webdynpro java.
    If u provide me with sample code it will become more usefull.
    Thanks & Regards,
    SN

    HI,
    Please find the steps:
    Create a html file and store in your webdynpro project
    Add the html contents in your file
    & Create a IFRAME UI element and refer you html file
    Now you able to see the html in webdynpro
    Thanks & Regards,
    Ram

  • How to download itunes and how to use windows in my iPad?

    How to download itunes and how to use windows in my iPad?

    The iTunes  app comes pre installed on your iPad.
    Use Windows? The iPad is an iOS device. Not possible to run Windows on an iPad.

  • How To use window.print() into Button Attributes

    hi,
    I want to print a report using an print button.so i am using window.print() function into Button Attributes .But Print pop up screen not pop up . How To use window.print() into Button Attributes      .
    Thanks
    Manoj

    dear hari
    "Set button target as URL and put following js as URL Target
    javascript:window.print();"
    Will this be useful to my another thread raised as follows.
    In case, if i am able to generate report as txt (ascii) file instead of doc / pdf and is it possible to send the txt file using host command. I am uable to try since i do not know where to place host command on click &print.
    yours
    dr.s.raghunathan

  • How to code vista like themes in java??

    freinds!! need sum help... can any one guide me of how to code files or themes in java?? is it related to Jmonkey and other 3d apps??
    if java is nt an efiicent lang in this feild.. them what is?? basically i wana know how to code themes for my desktop..
    i have read soome look and feel pluggables.. but i want stuff vista style!! plz help me..

    http://javootoo.l2fprod.com/ lists all available third-party look-and-feels. If you don't find the one that works best for you, download the source code for the open-source ones and see how it is done.

  • How to view live webcam that use windows media player and java

    I am new to iphone and I have two live webcams that I like to go to and can't get either one on my iphone 3gs. www.ruidoso.net, view live webcam link and www.skiapache.com live webcam link. How can I get to them?? oram I just out of luck.

    You've got to remember that, as powerful as the iPhone is, it's not a desktop computer. So certain things that have been designed for desktop computers may not work the same or at all. The owners of those websites probably never considered anyone wanting to view them on a phone.
    The first webcam you can view on your iPhone by going to http://www.ruidosowebcam.com/camera0.jpg and manually refreshing the page to update the view. (The Java applet just refreshes the page, something they could easily have done in JavaScript for increased compatibility).
    The second one I can't help with, as that one doesn't even work on my desktop computer, but WMV is a proprietary video format from Microsoft, which the iPhone doesn't play. You'd have to ask the website owners to use a more industry standard video format that the iPhone can play.

  • How to use windows environment variable "%appdata%" in TEXT_IO built-in

    Hello Sir/Madam,
    I'm currently using TEXT_IO built-in package to write data file user's "C" drive in Oracle Forms 6i on Windows XP OS. We are in the process of upgrading the OS to Windows7. This new version does not allow to write to "C" or "D" drive. I was wondering how I can use windows environment variable "%appdata%" in this built-in to write the data file to user's AppData folder?
    I would appreciate your help.
    Regards,
    Vani Sonti

    You are obviously not familiar with the architecture of webforms. See here http://www.oracle.com/technetwork/developer-tools/forms/275632-133265.pdf
    I guess you are running your forms locally, so the forms server and the client run on the very same machine. This won't be the case once you run in production, as you will have an application server and clients connecting to the server.
    text_io, tool_env and all the forms built ins will be executed on the machine the forms runtime runs on, and in a 3 tier architecture this is the application server, not the client as the real client will run just a java applet which actually just does what the forms runtime on the server tells it to do (or passes client side events like mouse clicks to the forms runtime on the server).
    A very simple explanation for the architecture would be that the whole GUI part has been ripped off the forms runtime and put into a java applet; the logic part (the old-fashioned forms runtime) where the whole Forms PL/SQL code is executed communicates with the GUI part (which is implemented as a java applet) via HTTP, so there is no need to have both running on the very same machine.
    So if you are writing a file with text_io on c:\dummy.txt this file will be generated on the application server machine as it is executed where the forms runtime runs. If you read environment variables with tool_env.getvar you will get the environment variable from the application server machine.
    If you need those variables from your application server then those built-in packages are what you need, but if you need the real client variables there is no way around java in webforms 6i. But the beans should be simple enough to have them written within no time ;)
    cheers

  • How to Use COM Component in a Java Bean

    Dear Sir,
    How can I use a COM Component in a Java-Bean . I am having a COM Component for reading Weighment Reading on a Serial Port and want to use this Component in a Java-Bean . I would also like to call the methods of this COM Component inside my Java-Bean . COM Component is a dll file .
    Please guide me how to go ahead . If possible kindly provide some sample code for the same .
    With Thanks and Regards
    B V Mittal

    You need a Java to COM bridge like Jacob. Try searching this forum for more information, I've answered this question several times before.
    Dom.

  • How to use .properties files in Webdynpro Java code?

    Hi all,
      I want to use a logon.properties file when I initial a JCO connection pool in my webdynpro DC (JCO.addClientPool()),but  I found when I deployed this DC to the server, it always giv e me an FileNotFoundException. So I donot know how to deploy a .properties file to the server and how to access this file in my Java code?
    Thans and Best regards
    Deyang

    Hi,
    1) put .properties file to your packege under src\packages folder (src\packages\com\sdn\properties\jco.properties)
    2) load property:
         final InputStream is = getClass().getClassLoader().getResourceAsStream("com/sdn/properties/jco.properties");
         final Properties properties = new Properties();
         try
              properties.load(is);
         catch(Exception e)
              wdComponentAPI.getMessageManager().reportException(new WDNonFatalException(e), false);
    Regatds Maxim R.

  • How to use a swf file in java

    plz any body tell me about this
    that how to use SWF in java (JFrame)

    I suggest you look in google http://www.google.co.uk/search?q=SWF+java

  • How to use shell program parameters in java program??

    Hai all,
    I am writing a java program which must read strings from a file and must assign to variables.these strings are nothing but the output of ls -l command in shell. i need to have all those 9 fields in a file as variables.
    I cant find any method that will read only string.I came accross read line but that is not what i need.So, i thought of writing a shell script and by using awk, storing those 9 fields in 9 variables.. but how to use that variables in java programming???
    the shell script is executed by exec() but i need that variables also.
    Help me please:(
    thanks in advance

    i now changed the code... and closed the output file and then i read.Later i splited with the line i read.. but the same happened...
    this is the code:
    while ((l = inputStream.readLine()) != null)
                        op=new FileOutputStream("op.txt");//output of exec goes to this file
                        String[] cmd= {"/bin/sh","-c","ls -l "+l};
                        rt = Runtime.getRuntime();
                        proc = rt.exec(cmd);
                        // any error message?
                          StreamGobbler errorGobbler = new
                          StreamGobbler(proc.getErrorStream(), "ERR");
                        // any output?
                          StreamGobbler outputGobbler = new StreamGobbler(proc.getInputStream(), "",op);
                        errorGobbler.start();
                               outputGobbler.start();
                        op.close();//the file is closed now
                        ip = new BufferedReader(new FileReader("op.txt"));     //now i opened to read
                        p=ip.readLine();
                        a=p.split("\\s");
                        ip.close();
                   }where i went wrong?

  • How to Use GnuPG(GPG) winth in java

    Hi all
    I am having one tough time getting How to use GnuPg with in Java languge to encrypt and decrypt file. Can anyone offer any help ...
    Satya

    I'm using this wrapper founded somewhere. Works fine to me.
    /* License: GPL
    * Author: John Anderson
    * Description: A small class to encrypt and decrypt text using GnuPG.
    import java.io.*;
    public class GnuPG {
            private Process p;
            private String gpg_result;
            private String gpg_err;
            GnuPG() {
            public void verifySign(String signedFile, String originalFile){
                    System.out.print("Verifying...");
                    try {
                            //p = Runtime.getRuntime().exec("gpg --output "+originalFile+" --decrypt --yes --verbose " + signedFile);
                            p = Runtime.getRuntime().exec("gpg --verify " + signedFile);
                    } catch (IOException io) {
                            System.out.println("Error creating process.");
                    ProcessStreamReader psr_stdout = new ProcessStreamReader("STDIN", p.getInputStream());
                    ProcessStreamReader psr_stderr = new ProcessStreamReader("STDERR",p.getErrorStream());
                    psr_stdout.start();
                    psr_stderr.start();
                    BufferedWriter out = new BufferedWriter(new OutputStreamWriter(p.getOutputStream()));
                    try {
                            out.write("\n");
                            out.close();
                    } catch (IOException io) {
                    try {
                            p.waitFor();
                            psr_stdout.join();
                            psr_stderr.join();
                    } catch (InterruptedException i) {
                    gpg_result = psr_stdout.getString();
                    gpg_err = psr_stdout.getString();
                    System.out.println("Done.");
            public void encrypt(String str, String rcpt) {
                    System.out.print("Encrypting... ");
                    try {
                            p = Runtime.getRuntime().exec("gpg --armor --batch --encrypt -r " + rcpt);
                    } catch (IOException io) {
                            System.out.println("Error creating process.");
                    ProcessStreamReader psr_stdout = new ProcessStreamReader("STDIN", p.getInputStream());
                    ProcessStreamReader psr_stderr = new ProcessStreamReader("STDERR",p.getErrorStream());
                    psr_stdout.start();
                    psr_stderr.start();
                    BufferedWriter out = new BufferedWriter(new OutputStreamWriter(p.getOutputStream()));
                    try {
                            out.write(str);
                            out.close();
                    } catch (IOException io) {
                    try {
                            p.waitFor();
                            psr_stdout.join();
                            psr_stderr.join();
                    } catch (InterruptedException i) {
                    gpg_result = psr_stdout.getString();
                    gpg_err = psr_stdout.getString();
                    System.out.println("Done.");
            public void decrypt(String str, String passphrase) {
                    File f = null;
                    try {
                            f = File.createTempFile("gpg-decrypt", null);
                            FileWriter fw = new FileWriter(f);
                            fw.write(str);
                            fw.flush();
                    } catch (IOException io) {
                    System.out.print("Decrypting from: " + f.getAbsolutePath());
                    try {
                            p = Runtime.getRuntime().exec("gpg --passphrase-fd 0 --batch --decrypt " +
                                    f.getAbsolutePath());
                    } catch (IOException io) {
                            System.out.println("Error creating process.");
                    ProcessStreamReader psr_stdout =
                            new ProcessStreamReader("STDIN",
                            p.getInputStream());
                    ProcessStreamReader psr_stderr =
                            new ProcessStreamReader("STDERR",
                            p.getErrorStream());
                    psr_stdout.start();
                    psr_stderr.start();
                    BufferedWriter out = new BufferedWriter(
                            new OutputStreamWriter(p.getOutputStream()));
                    try {
                            out.write(passphrase);
                            out.close();
                    } catch (IOException io) {
                    try {
                            p.waitFor();
                            psr_stdout.join();
                            psr_stderr.join();
                    } catch (InterruptedException i) {
                    gpg_result = psr_stdout.getString();
                    gpg_err = psr_stdout.getString();
                    System.out.println("Done.");
            public String getResult() {
                    return gpg_result;
            public String getError() {
                    return gpg_err;
    class ProcessStreamReader extends Thread {
            String name;
            StringBuffer stream;
            InputStreamReader in;
            final static int BUFFER_SIZE = 256;
            ProcessStreamReader(String name, InputStream in) {
                    super();
                    this.name = name;
                    this.in = new InputStreamReader(in);
                    this.stream = new StringBuffer();
            public void run() {
                    try {
                            int read;
                            char[] c = new char[BUFFER_SIZE];
                            while ((read = in.read(c, 0, BUFFER_SIZE - 1)) >
                                    0) {
                                    stream.append(c, 0, read);
                                    if (read < BUFFER_SIZE - 1)
                                            break;
                    } catch (IOException io) {}
            String getString() {
                    return stream.toString();
    }

  • How to use File Transfer Protocol in Java?

    hi all,
    im new to java. i dont know how to use FTP in java. but i want to transfer files from my machine to another machine and also i want to download files from that machine through FTP. how can i start this program. pls any one give me the code for this program. thanks in advance.

    Of course you didn't get an "exact result", since that link was to an article which reviewed several products. If you aren't capable of making a decision based on that article, try using the Apache Commons/Net FTP component.

  • How to use to_char(oracle function) in java

    Hi,
    I am getting the value as a integer from one table in my java file and want to insert it into another table as a varChar..
    I found one method in oracle like to_char().. can i use this in java..
    can u pls let me know how to use this in java..or is there any other way to convert it..
    for example, i am getting the value is : 4 (number) from one table. and want to insert it into another table like : 04 (varchar)..
    how can i convert it and insert into another table as a varchar..
    please help me

    Well part of the answer depends on what db your using but semantically if I just HAD to do what you're doing I would use a stored procedure to do the insert into the second table or better yet do the whole thing in a stored procedure which would make life much easier all the way around.
    Implicit lesson here: Use the RIGHT tool for the job at hand.
    The big question though is why do you have data that's of one type in one place and another type in another place?
    PS.

Maybe you are looking for