How to open avi's and mp3's in associated programms

Hi, I wanted to open external file from java in program asociated with this file
I've used :
File doc = new File("C://myTxt.txt");
Desktop dt = Desktop.getDesktop();
dt.open(doc);... i've tested it with txt's, jpegs' and it works perfectly....
but when i wanted to open *.mp3 files, code crashes with this output:
SEVERE: null
java.io.IOException: Failed to open file:/C://mp3/Lightbringer.mp3. Error message: Parameter is wrong.
at sun.awt.windows.WDesktopPeer.ShellExecute(WDesktopPeer.java:59)
at sun.awt.windows.WDesktopPeer.open(WDesktopPeer.java:36)
similar problem ocurred with avi's....
I'm new to Java, so I think I can't solve it on my own...
So, please, do you know any solve of this problem?

Thanks for very fast reply... But it doesn't work -> I've tested it with this String in file constructor ("C:\TEST.mp3";) and caught this exception:
java.io.IOException: Cannot run program "C:\TEST.mp3";;: CreateProcess error=193, %1 nen� platn� aplikace typu Win32
+("nen� platn� aplikace typu Win32" == isn't Win32 aplication), i'm Czech, gg:)+
mp3's and avi's don't work too :( ;
syntax, that I've used: Runtime.getRuntime().exec("C:\TEST.mp3";); but for your fast reply, one Duke is yours:)
Note: i don't want exec an application, with known name, but default application. In exec(), is possible to do it like this: exec("notepad.exe -"+String_filename);... But i want to get default program in wich can i execute that file...

Similar Messages

  • How to open a page  and closing source page in jdev 10.1.3.3

    how to open a page and closing source page in jdev 10.1.3.3.
    for example.
    From page 'A' , we are opening a page 'B' and closing the page 'A'. how this can achived.Please let me know

    Your question is totally not clear?
    What page? a JSF page? A code editor in JDeveloper?

  • How to open .rar files and .exe files on mac

    HI
    I'm new user on mac and would like to know how to open .rar files and .exe files on MAC OS X
    Thanks

    How is this a Compressor question?
    .exe is a Windows only Executable, and can't be opened on a Mac, unless you have Windows installed.
    Michael Trauffer

  • How to open AVI files?

    I have six AVI files that I very much need to see.   They come on a CD-ROM.  I have transferred them to my hard drive.   They do not work from either the CD-ROM or the hard drive.
    GetInfo identifies these videos as “AVI movie.”
    The closest I can get is with Real Player, Version 12.0.1 (1750).  This application opens a window for each file.  The thermometer across the bottom of the window moves as if the application is playing the video, but the window remains totally black.   (The videos should not have any sound, so I do not expect to hear anything from them.)
    I have no luck at all with VLC and QuickTime Player.  VLC, Version 2.0.7 Twoflower (Intel 64bit), reports:
    QuickTime Player, Version 10.0 (131), reports:
    I get this problem with videos from people who do not use Macinstoshes.  
    Does anyone know how to open such AVI files? 

    I have Perian 1.2.3.  Its update function reports that is the latest version.  
    Perian's GetInfo has the following report, which says nothing about the T263 codec:
    About
    Perian aims to provide a single package for all your playback needs.  It is a collection of QuickTime components incorporating several libraries:
    • libavcodec, from the ffmpeg project, along with code from the old FFusion component:
              • MS-MPEG4 v1 & v2
              • DivX
              • 3ivx
              • H.264
              • Flash Video
              • Flash Screen Video
              • On2 VP3, VP6, VP8
              • H263I
              • HuffYUV and ffvhuff
              • Indeo 2, 3 & 5
              • MPEG-1, 2 & 4 Video (in supported formats)
              • Fraps (up to v4)
              • Windows Media Audio v1 & v2
              • Flash ADPCM
              • Xiph Vorbis (in Matroska)
              • MPEG Layer I and II audio
              • DTS Coherent Acoustics audio
              • Snow wavelet video
              • DosBox video
              • Nellymoser ASAO audio
    • libavformat, from the ffmpeg project. along with AVIImporter.component:
              • AVI file format
              • FLV file format
              • NUV file format
    • libmatroska, along with matroska-qt.component:
              • MKV file format
    • Subtitles:
              • (Advanced) SubStation Alpha
              • SRT
              • SAMI
              • VobSub
    • liba52, via A52Codec:
              • AC3 audio
    The code is available under the LGPL. The development site is located at <http://trac.perian.org/> and the project's Subversion repository is located at <http://svn.perian.org/>.
    The code for A52Codec is available under the GPL. The project site is located at <http://trac.cod3r.com/a52codec/> and the project Subversion repository is located at <http://svn.cod3r.com/a52codec/>.

  • How to open new window and generate oracle report from apex

    Hi,
    I had created an application that generates PDF files using Oracle Reports, following this Guide.
    http://www.oracle.com/technology/products/database/application_express/howtos/howto_integrate_oracle_reports.html
    And I followed 'Advanced Technique', so that users can't generate PDF file by changing URL and parameters. This is done for security reasons.
    But in this tutorial, when 'Go' button is pressed, the PDF file is displayed on the same window of apex application. If so, user might close the window by mistake. In order to avoid this, another window have to be opened.
    So, I put this code in the BRANCH - URL Target. (Note that this is not in Optional URL Redirect in the button property, but the branch which is called by the button.)
    javascript:popupURL('&REPORTS_URL.quotation&P2100_REP_JOB_ID.')
    But if the button is pressed, I get this error.
    ERR-1777: Page 2100 provided no page to branch to. Please report this error to your application administrator.
    Restart Application
    If I put the code 'javascritpt ....' in the Optional URL Redirect, another window opens successfully, but the Process to generate report job is not executed.
    Does anyone know how to open new window from the Branch in this case?

    G'day Shohei,
    Try putting your javascript into your plsql process using the htp.p(); procedure.
    For example, something along these lines should do it:
    BEGIN
    -- Your other process code goes here...
    htp.p('<script type="javascript/text">');
    htp.p('popupURL("&REPORTS_URL.quotation&P2100_REP_JOB_ID.")');
    htp.p('</script>');
    END;
    What happens is the javascript is browser based whereas your plsql process is server based and so if you put the javascript into your button item Optional URL Redirect it is executed prior to getting to the page plsql process and therefore it will never execute the process. When you have it in your branch which normally follows the processes, control has been handed to the server and the javascript cannot be executed and so your page throws the error "Page 2100 provided no page to branch to"... By "seeding" the plsql process with the embedded javascript in the htp.p() procedure you can achieve the desired result. You could also have it as a separate process also as long as it is sequenced correctly to follow your other process.
    HTH
    Cheers,
    Mike

  • How to open an URL and close the URL window, using adobe javascript

    Hi,
      Is it possible to open an URL and close the URL back again(without allowing the user to perform any other operation)? I was able to acheive the opening of the URL, using the app.launchURL("address". true); - But here it lauches in new window, and how do i close the window using the javascript. Is it possible?
    Thanks.

    Hi all
    In addition to what Bobby W - Adobe TS added, you might find
    the following useful as a bypass or workaround to the pesky prompt.
    var pw=window.parent;pw.opener=window.self;window.open("
    http://www.adobe.com");
    pw.close();
    I think this will only work for IE browsers. Actually, I
    think the whole window.close() only works for IE, but could be
    wrong about that.
    Cheers... Rick

  • ITunes and QT crashes when trying to open mp4, wav and mp3

    Hi.
    QT or iTunes crashes when I try to open files such as MP3, MP4 and WAV. And even when I want to watch a video on Youtube so it only plays 2 seconds and then white box.
    I've installed QT X and then removed it and re-installed QT7 because I thought that was the problem, but I have the same problem even after re-installation of the QT Player 7 by the OSX installDVD.
    Can anyone here tell me what is the solution to this?
    Thanks.
    More info:
    Perian 1.2.3 and Flash Player are installed.

    Can anyone here tell me what is the solution to this?
    Usually by a logical process of elimination. The first step would normally be to determine if the proble is local or global. This can be tested by thre creation of a second user account and checking to see if the same problem exists. I.e., if the problem does not exist, then it is local to you first user account and may be something as simple as a corrupt PLIS file. On the other hand, if the proble exists in both user accounts, the it is a global problem like a corrupt application, a conflict with another app, or an OS-wide problem. Basically, the results of each test gives some indication of what you should try next.

  • Total Newbee, How to open ports 5198 and 5199 for Amateur Radio software program

    I am a Amateur Radio operator using a software program called Echo Link which will enable me to talk to other radio operators around the would through repeaters running this software.  I need to open ports 5198 and 5199 in my Airport Time Capsule for this software to work.  How do I open these ports?  They talk about mapping the ports which I don't understand.  Below is a screen shot of an older version of Airport that shows what I want to do.
    I tried to do it but it does not work and I can't change the private IP Address.  Here is a screen shot of what I tried to do below.  Thanks for any help you can provide. 

    It says above 2 relevant and 1 correct answere available .............
    I'm new here so could anyone direct me to these answeres?

  • How to open ports 80 and 443

    How do you open ports 80 and 443?  I'm trying to connect a tv to the internet.

    What router are you using? Who is your ISP? Also, what exactly are you trying to accomplish?

  • How to open avi with 'motion jpeg' codec

    I am trying to open avi files stored on sd memory card from a casio exilim camera. Prism shows it as being a 'motion jpeg' codec. 'Open AVI' VI thows up an invalid avi session code when I try to open with labview. I'm using Labview 2011.

    LabVIEW AVI VIs rely on the installed codec to encode/decode.
    You need download a codec for the motion jpeg.
    It's very easy to find a free codec for it online.  Search bing or google instead of NI.
    George Zou
    http://webspace.webring.com/people/og/gtoolbox

  • How to open up MBP and take out the DVD

    My son just put another DVD in my MacBook Pro 15" while watching anoter DVD. Now they are both stuck and doesen't eject. Is it possible to open the computer and take 'em out myself?

    Follow this guide to open the computer all the way to the DVD drive.
    http://www.ifixit.com/Guide/Mac/MacBook-Pro/SuperDrive
    I would try and take it out with a paperclip or something before you open up the computer.

  • How to open a file and display the complete file path?

    In my script, I want to create a dialog that prompts the user to define a few variables for the script. One of those variables is the path to a template file. I want it to work the same way that an upload form works. You click the browse button, the dialog appears so that you can browse for the file and then when you click OK or Open, the full path of the file is displayed in the text box next to it. How do I do this with JavaScript? I got this far and it seems to be working, but the wrong text is being displayed in the text box. Plus: How do I properly restrict the file types to PSD. The code doesn't seem to work, despite the fact that there are no errors reported. Initially the Text box is blank, but After I browse for the file, the text box says: "File". Here is the problem area:
    defineVars.STPnl.STBrowse.onClick = function browseST() {
    var stbFile = File.openDialog("Select the Single Mugshot Key Template File", "File Types: *.psd, *.PSD");
    defineVars.STPnl.STPath.text = stbFile;
    Thank you to whoever assists me! :)

    Change this:
    defineVars.STPnl.STPath.text = stbFile;
    To this:
    defineVars.STPnl.STPath.text = stbFile.fullName;
    The reason is that stbFile is a File object, you need to access its properties in order to get the full path.

  • APEX- How to open world document (and other files) stored in a blob column?

    Hi,
    I have an application developed in Oracle Apex 3.2.1 and RDBMS Oracle 9.2.0.8 (SUN SOLARIS SPARC 64 BITS).
    I have a table called BAC_ARQUIVO, with the following structure:
    CREATE TABLE BAC_ARQUIVO
    (NAME VARCHAR2(4000), /* Name of the file stored in BLOB column */
    SUBJECT VARCHAR2(4000), /* A brief description about this file stored */
    ID NUMBER, /* An identification of this file - It´s a PK column of this table*/
    BLOB_CONTENT BLOB, /* Blob field that store diferent kind of files - XLS, DOC, PPT, PDF, EXE, ZIP, etc);
    MIME_TYPE VARCHAR2(4000) /* Identification about which kind of file is stored on BLOB field */
    The field BLOB_CONTENT of this table can store:
    - Executable files;
    - MS-World Documents (DOC);
    - Zip Files (ZIP);
    - Ms-Excel Files (XLS);
    - Ms-Powerpoint files (PPT);
    - Adobe documents (PDF);
    Actually, in this APEX application, i have developed a interactive Report in which the user can download these files to desktop without problems.
    But now, my user would like to know if it´s possible that APEX application can OPEN some of these files stored on this BLOB column WITHOUT download it.
    My user would like to see a hiperlink (or button) that, if pressed/acessed, can open a new page (or a page inside application) with the document. He doesn´t need to edit this oppened file. He only wants to see it.
    For example, if the file stored in the blob column is ms-word type , so the application will open a MS-WINDOWS application with these file.
    Is it possible?
    I saw in this forum that it´s possible to open a file stored on "/i/" directory, but i need to open the file stored in BLOB column. I don´t want to store the file in operational system of the server.
    Could any one demonstrate to me how it could be done?
    Best regards,
    Sergio Coutinho

    Hi Sergio,
    This link might be helpful:
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/db/apex/r31/apex31nf/apex31blob.htm
    Also refer the BLOB Download Format Mask :
    {message:id=9716335}
    Here I have given the format mask for APEX 4.0, which will slightly differ for 3.2.1 and proposed changes
    in the format mask are:
    1) Format Mask: DOWNLOAD
    2) Content Disposition: Inline
    This will be achieved with it:
    >
    But now, my user would like to know if it´s possible that APEX application can OPEN some of these files stored on this BLOB column WITHOUT download it.
    My user would like to see a hiperlink (or button) that, if pressed/acessed, can open a new page (or a page inside application) with the document. He doesn´t need to edit this oppened file. He only wants to see it.
    >
    Hope it helps!
    Regards,
    Kiran

  • I just received Adobe Elements 9 and want to how to open find "Bridge" and open it.

    I just received Adobe Elements 9 and want to know how to find "Bridge" and open it.  How do I go about that?

    I don't think PS Elements ever came with Bridge.  And Elements 9 is way old.  Believe current version is 11.

  • How to open .divx files and AC3 codecs?

    Hi,
    I am new at Macbook. I just got it one week ago, and i dunno how to use it, but I love my mac...
    My question is how can I play .divx files, and some of the movies I have coded with ac3, so how can I play them?
    thanks,

    Hi ecetin and welcome to the forums!
    Congratulations on the new macbook - I hope you will both be very happy!
    Here is the 'full nine yards' on what you need:
    These are the downloads and the settings you need in order to view/hear pretty much everything that the net can throw at you: The setup described below has proved repeatedly successful on both PPC and Intel macs, but nothing in life carries a guarantee!
    It is known to work in the great majority of cases with Safari 3.0.4, 3.1, 3.1.1, QT 7.3, 7.4.x and 7.5 and OS 10.4.11.
    Assuming you already run Tiger versions OS 10.4.11 and have Quicktime 7.4 or above, and are using Safari 2 or 3, download and install (or re-install even if you already had them) the latest versions, suitable for your flavor of Mac, of:
    RealPlayer 11 (which is no longer in beta) for Mac from:
    http://www.versiontracker.com/dyn/moreinfo/macosx/15540
    Flip4Mac WMV Player from http://www.microsoft.com/windows/windowsmedia/player/wmcomponents.mspx (Windows Media Player for the Mac is no longer supported, even by Microsoft)
    Perian from http://perian.org/
    You should read this support page http://perian.org/#support in case you need to delete older codecs.
    Adobe FlashPlayer should first be uninstalled using the appropriate uninstaller available here:
    http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_14157&sliceId=2
    and then the latest version obtained from here:
    http://www.adobe.com/shockwave/download/download.cgi?P1ProdVersion=ShockwaveFlash
    and installed.
    (You can check here: http://www.adobe.com/products/flash/about/ to see which version you should install for your Mac and OS, but please see my footnote if you are running Leopard.)
    In earlier versions than QT 7.1.3 in Quicktime Preferences, under advanced, UNcheck Enable Flash, and under Mime settings/Miscellananeous only check Quicktime HTML (QHTM).
    You should also ensure, if you are running Tiger 10.4.11, that you have downloaded and installed all the correct version for your Mac of Security Updates up to and including 2008-004. (N.B. Security Updates require both a restart and a permission repair.)
    In Macintosh HD/Library/Quicktime/ delete any files relating to DivX (Perian already has them). However it should be noted that Perian is not an internet plugin and will not play DivX files imbedded on a website. For that you will need the DivX Player browser plugin available from http://www.divx.com/divx/mac/
    Now go to Safari Preferences/Security, and tick the boxes under Web Content (all 4 of them) to enable Java.
    Lastly open Audio Midi Setup (which you will find in the Utilities Folder of your Applications Folder) and click on Audio Devices. Make sure that both Audio Input and Audio Output, under Format, are set to 44100 Hz, and that you have selected 'Built in Audio'.
    Important: Now repair permissions and restart.
    You should also consider having the free VLC Player from http://www.videolan.org/ in your armory, as this plays almost anything that DVD Player might not.
    There is an additional 'fix' you could try if you are having problems with Flash and Quicktime, depending on which type of Mac you have:
    On Intel Macs, make sure that you are not running Safari in Rosetta. You can check this, and change it, in the Get Info window.
    On PPC Macs, go to the Hard Disk/Library/Internet Plug-Ins folder, and drag the file 'QuickTime Plugin.webplugin' to the desktop. Quit and restart Safari. If things have improved you can trash that file. If they haven't put it back, as the lack of this plug-in can cause QT content in some widgets to cease functioning.
    And now there is an additional kid on the block: SilverLight. Microsoft has created their own version of what a replacement for Flash should be. You can read more about it here:
    http://silverlight.net/
    So, if you go to any sites that have been designed for this new Silverlight stuff, you can download the plug-in from here (but make certain that you are downloading SilverLight v.1.0 for OS X (10.4.8 upwards):
    http://silverlight.net/GetStarted/
    FOOTNOTE
    If you are running Leopard:
    Some users have mentioned that the latest Flash Player (v.9.0.115.0) conflicts with Leopard, and that they have needed to revert to v. 9.0.47. This can be downloaded from here:
    http://kb.adobe.com/selfservice/viewContent.do?externalId=tn_14266&sliceId=1

Maybe you are looking for

  • Remove and/or change password Sun Java System Web Server 7.0U3

    Running SJSWS 7.0U3 on Solaris 10 U6 I have access to the physical box the server is running on. I must have set something by mistake, now trying to connect to http://ipaddres/host:80 I get prompted for a username password. This is NOT the admin pass

  • Ipod Classic 80 & iTunes 9 syncing of contact and calendars no longer

    Itunes 9 doesn't seem to allow my 80 gg ipod classic to sync contacts and calendars. It says I don't have and and would I like to open iCal/Address Book to create some. I did get one notice that itunes no longer syncs contacts on my ipod... it appear

  • Budget exceeded WBS element

    I am creating purchase order for WBS element of amount 76214 USD but getting error Budget exceeded. Details of WBS element is (checked through CJ31) Distributable 807,800.00  USD and  Assigned 847,753.97  USD. Please can you help how to check balance

  • What's the best setting for a best shades quality?

    Hi! I would like to know what are the best codec and the best setting for a video with 1920x1080 of resolution. I've tried them all but nothing because the shades...are not shades. I want a video that is like a uncompressed video but lighter. Same qu

  • Java HTTPS  Exception

    Dear friends, I was trying to access ssl enabled website using the below program: import java.net.URL; import java.io.*; import javax.net.ssl.HttpsURLConnection; public class Test public static void main(String[] args) throws Exception String httpsUR