Can i open a flase file from java application?

i want that when the user click a button on my java application,
a flash file i made (Not html)will be showen .

is it an executable(*.exe?), if it is then you could try using runtime.exec() to run it, but it would not be in a window that you created

Similar Messages

  • How to open an PDF file from Java Application

    Hi
    I am developing a GUI application in java swing.
    on clicking one button, I want to open PDF file from my swing application.
    Is there any API through which I can achieve this?
    Tapan Maru
    Sun Certified Java Programmer

    Here's a way to do it (if I understand you
    correctly). Just let explorer.exe do it for you.
    import java.awt.*;
    public class openPDF
         Desktop desktop = Desktop.getDesktop();
         public openPDF()
              open("test.pdf");
         public void open(String path)
              try
                   Runtime.getRuntime().exec("explorer.exe "+path);
    } catch(Exception e) { System.out.println("NAI!
    I! ERROR!\n"+e); }
         public static void main(String[] args)
              openPDF myApplication = new openPDF();
    Why do you have a Desktop object as a member but instead of using it, you execute a command with Runtime (which is not platform independent!)???
    -Puce

  • I can't open or save file with Java Web Start

    Hi,
    i can't open or save file with Java Web Start:
    import java.io.*;
    import java.util.*;
    public class MetaDataFileCreator {
    public String fileNameSpace = null;
    public String fileName = null;
    protected Properties file = null;
    public MetaDataFileCreator(String fileNameSpace, String fileName) {
    this.fileNameSpace = fileNameSpace;
    this.fileName = fileName;
    public void createMetaDataFile() {
    try {
    System.out.println("file METADATA");
    ClassLoader cl = this.getClass().getClassLoader();
    String nameFileMetaData = fileNameSpace + fileName + ".txt";
    FileOutputStream fileOS = new FileOutputStream(cl.getResource(nameFileMetaData).getFile());
    file = new Properties();
    file.setProperty("aaaaa", "aaaa");
    file.store(fileOS, "");
    fileOS.close();
    } catch (Exception e) {
    System.out.println("Error writing metadata-file: " + e);
    System.exit(1);
    e.printStackTrace();
    I have try also to open a file like this:
    ClassLoader cl = this.getClass().getClassLoader();
    file.load(cl.getResourceAsStream(nameFile));
    also like this:
    try {
    fos = (FileOpenService)ServiceManager.lookup("javax.jnlp.FileOpenService");
    fss = (FileSaveService)ServiceManager.lookup("javax.jnlp.FileSaveService");
    } catch (UnavailableServiceException e) {
    fss = null;
    fos = null;
    System.out.println("Error with JNLP");
    System.exit(1);
    if (fss != null && fos != null) {
    try {
    // get a FileContents object to work with from the
    // FileOpenService
    FileContents fc = fos.openFileDialog(null, null);
    //FileContents newfc2 = fss.saveAsFileDialog(null, null, fc);
    // get the OutputStream and write the file back out
    if (fc.canWrite()) {
    // don't append
    os = fc.getOutputStream(false);
    } catch (Exception e) {
    e.printStackTrace();
    also like this:
    File f = new File((System.getProperty("user.home")+"x.txt").toString());
    FileOutputStream fileX = new FileOutputStream(f);
    OutputX = new PrintWriter(new BufferedWriter(new OutputStreamWriter(fileX, "UTF8")));
    OutputX.println(....
    but it doesn't work with Java Web Start.
    Can someone help me?
    How can I open or save file?
    thank you.
    Sebastiano

    Did you specify <all-permissions/> in your JNLP file? Did you sign your code? What error are you getting?

  • Can't open web pdf files from my Reader DC because my IMac wants a completed license agreement to use Reader and I never saw that page during installation.

    Can't open web pdf files from my newly installed Reader DC because my IMac wants a completed license to use agreement to Reader, and I never saw that page during installation.  How do I get past this?

    You need to accept the EULA on first launch of the Reader DC application.
    Go to the Applications folder and launch Adobe Acrobat Reader DC. 
    This will bring up the EULA.
    Select the "Agree" button if you agree with the terms
    Assuming you selected the "Agree" button, Reader DC should open.
    You should now be able to open PDF files in your web browser.

  • I can't open the RAW files from my new Nikon D4s camera in photoshop? How do I download the latest software for RAW files?

    I can't open the RAW files from my new Nikon D4s camera in photoshop? How do I download the latest software for RAW files? Cheers!

    What version of Photoshop are you running?  You will need at CS5, CS6, CC or CC2014.  Each version needs a different ACR-plug-in to open files from that camera.
    If you are on CS4 or earlier, you'll need to upgrade—or, in the alternative; look for, download, instal, launch and run the free, stand-alone DNG Converter 8.6 on each file of raw NEF files to convert them to raw DNGs first so you can open them in your version of Photoshop and ACR plug-in higher than 2.4.

  • I have Lightroom 3.6 and Camera Raw 6.6 but I can't open my CR2 files from my Canon eos 6D

    Hi,
    I have Lightroom 3.6 and Camera Raw 6.6 but I can't open my CR2 files from my Canon eos 6D
    Lightroom doesn't show a thumbnail image and when trying to import it says the camera format isn't supported. But normaly Camera raw 6.6 should cover the Canon eos 6D
    All help is welcome,
    Thanks

    No, the older versions are not free.  If you upgrade you will have to get Lr5 unless you can still find Lr4 for sale somewhere as it has been discontinued by Adobe.  You can also use the FREE DNG converter to convert the 6d files for use in Lr3.6.

  • I can not open raw image files from my Cannon 5d mark iii with cs6 and my cs6 in mac

    I can not open raw image files from my Cannon 5d mark iii with cs6 and my cs6 in mac

    The Mk III requires an updated version of Camera RAw, so run Help --> Updates and install it.
    Mylenium

  • Photoshop :: Can't Open Latest NEF Files From New D610

    I Can't Open Latest NEF Files From New D610.it can't open naturaly in photoshop CS6.

    Have you updated Camera Raw, which exact version is it?
    See this list to verify which version supports which cameras:
    Camera Raw plug-in | Supported cameras

  • I have just bought a Panasonic Lumix compact camera. Aperture and Preview can't open the RAW files from this camera. Panasonic recommend downloading 'SYLKPIX Developer Studio SE' to save RAW file formats.How can Aperture and Preview read the files?

    I have just bought a Panasonic Lumix compact camera. Aperture and Preview can't open the RAW files from this camera. Panasonic recommend downloading 'SYLKPIX Developer Studio SE' to save RAW file formats.How can Aperture and Preview read the files?

    Either use 'SYLKPIX Developer Studio SE' to develope the RAW files and to save them in another lossless format like TIFF, or try if Adobe's free DNG Coverter can convert your Lumix RAW files to dng. Then import the dngs. This way, your files will still be RAW files.  This works (most times) for my Lumix FZ28.
    Adobe DNG Converter 8.3  http://www.adobe.com/support/downloads/detail.jsp?ftpID=5695

  • I can't open adobe ideas files from ps touch via the cloud. How do I do this?

    I can't open adobe ideas files from ps touch via the cloud. How do I do this?

    Oh good lord.  I can't believe I spent so much time on this and it's right there under Google.  Thank you so much!  Happy Thanksgiving!
    Laura
    Check me out @ http://www.lauramacky.com/

  • How can I open OS 9 files from my old computer on my 2012 MacBook Pro?

    How can I open OS 9 files from my old computer and use them on my 2012 MacBook Pro?
    David

    GriffinParkCondos wrote:
    How can I open OS 9 files from my old computer and use them on my 2012 MacBook Pro?
    David
    What type of files?
    Pete

  • How can i call forpro prg file from java

    Hai friends,
    I have a doubt,clear it.
    how can i call forpro prg file from java file
    by,
    N.Vijay

    Thanks to your reply,
    I have some print statements in my foxpro program file.
    Then i like to invoke that foxpro file from my java file
    This want i want..,
    by,
    N.Vijay

  • Running exe files from java applications

    Hello All,
    Is it possible to run executable files from java applications?
    I need to run an exe file on the client from the server machine, the exe could reside on either the server or any other machine on the LAN. Is it possible to specify the path of where the exe resides, and run it on a client machine?

    HI,
    I tried to launch a MS Word application using runtime.exec but it gives me some problem
    The foll. code to launch a txt file using notepad works.
    Runtime rt = Runtime.getRuntime();
    String[] callAndArgs = {"notepad.exe","C:\\coo7\\wizard.txt"};
    Process child = rt.exec(callAndArgs);
    However, oif I try to launch a MS Word application, it asks for the entire path of WINWORD.exe, (unlike just specifying notepad.exe as the first argument in String[] callAndArgs) and this can vary from one machine to another.. how do I get around this?
    The foll. code snippet works but the complete path of where WINWORD.exe might be installed on any machine, is not fixed:-(
    Runtime rt = Runtime.getRuntime();
    String[] callAndArgs = {"C:\\Program Files\\Office\\Office10\\WINWORD.exe","C:\\coo7\\wizard.doc"};
    Process child = rt.exec(callAndArgs);
    Any idea/suggestions pls..

  • Can I execute MySql's command from java application?

    Can I execute MySql's command from java application? And how?
    For example :
    load data local infile 'D:\\myData.txt'
    into table myTable
    fields terminated by ';'
    lines terminated by '\n';

    1. get the jdbc driver for mysql from the mysql site at: http://dev.mysql.com/downloads/connector/j/5.0.html
    2. follow the installation instructiions... which you'll also find in your mysql manual...
    Happy travels. Keith.

  • Opening jpg/pdf files from Java

    Hi,
    How can I open jpg/pdf files or any file in general from Java, such that they open up in the default program in Windows?
    I dont want to read in the files using Java. Just open them in their default program. Eg. PDF should open in Adobe.
    thanks,
    parsifal

    Thanks both of you for answering.
    You don't need to make a map. You need the "cmd /c
    start" command in Windows.This is what I was missing. I looked up DOS commands to open a files in window but couldnt get it. So I thought java would have some command that equals double-clicking icons on window.
    Thanks.
    best,
    parsifal

Maybe you are looking for

  • Display the all text entered for all folder at Item and Header level of PO

    Hi everybody, I have the task like the following : In a PO there are text folders available at Header and Item level. I want POs with type Purchasing document type u2018ZFu2019 ( First Article PO ) should display all the texts entered into any of the

  • HT1390 Movie rental disappeared on iTunes

    (last sunday Oct / 21st) 2nd time I rented a movie called Safe House through iTunes and magically it disappeared! Just some notes: 1) I have: apple tv 1st gen, an apple tv 2nd gen and an iPhone 4S. Just checked and it is not there 2) I am quite posit

  • Can I rotate iBooks Author widgets?

    Hello, I wonder it is possible that I can rotate iBooks Author widgets? For an example, can I rotate Gallery widget? Thanks,

  • V12 export to V11 server?

    Hi, The "how to" upgrade article at http://azure.microsoft.com/en-us/documentation/articles/sql-database-preview-plan-prepare-upgrade/ claims that export/import to V12 is now supported (the comments seem to suggest that this was previously _not_ supp

  • BLACKBERRY DESKTOP SOFTWARE and OSX Lion

    Dear all I have a new MacPro with latest OS XLion and after installed blackberry desktop software all system started go very slowly. I called Apple support and  they told me that BB has not any update that works with new OS X Lion system and installi