How can I open a relative path

Does somebody knows how can I open a relative URL from an applet by the
getAppletContext().showDocument(new URL("http://java.sun.com"), "_blank");
instruction?
I mean, I want to open a html page stored in my hard drive but if I change the "http://java.sun.com" to, for example, "Mi documents/index.html" it doesn't works.
Could sombody help me with this please?

Well, in fact you can in a special case :
- The file you want to access is in the same directory than the applet (or in a sub-directory)
If this condition is OK, you can open the file using :
java.io.InputStream MyInputStream = <YourAppletClassName>.class.getResourceAsStream("sidira_interactif2.svg")
With this stream, its easy to read the file content.

Similar Messages

  • How can I use a relative path in a Virtual Directory tag?

    That is probably a bit vague, so I will explain in more detail. We are using BEA
    WL Portal 7.0 and our team is developing multiple portal applications. We have
    a core set of portlets (consist of JSPs) that we need to reuse in multiple portals
    (Web Apps), however from a version control perspective they need to reside in
    one common location. So, the solution I came up with is to use a virtual directory
    for the the common directory and add this to weblogic.xml for each web app. This
    works fine. However, each developer has different directory names for their project...ClearCase
    view names to be specific... plus we have integration views, QA views, etc...
    so we can't have any "C:\mystuff\mydomain" absolute paths anywhere in the portal
    configuration. Does anyone know of a way to use a relative path for a virtual
    directory? I have tried various versions of ../../ for example to try to backup
    and then recurse down to the directory, but this is not working. Any ideas?
    By the way this is basially just a hack for development, when we package the WAR
    for QA, Prod, etc... we copy needed files and there are no virtual directories.
    In other words, I don't care how "creative" solution is :)
    This is what I have right now, which I need to replace with a relative directory
    name:
    <virtual-directory-mapping>
    <local-path>C:/Projects/TouchPoint_v1.0_Fix/tp_portal/bipiportals/beaApps/portalApp/tp-shared</local-path>
    <url-pattern>*</url-pattern>
    </virtual-directory-mapping>

    Well, in fact you can in a special case :
    - The file you want to access is in the same directory than the applet (or in a sub-directory)
    If this condition is OK, you can open the file using :
    java.io.InputStream MyInputStream = <YourAppletClassName>.class.getResourceAsStream("sidira_interactif2.svg")
    With this stream, its easy to read the file content.

  • How can I open a Form located in UNIX

    Hi all,
    I have a problem!
    The system in my company is a 3-tier architecture:
    Database-tier: SUN SOLARIS
    Middle-tier (Oracle Application 11i): SUN SOLOARIS
    Clien-tier: Windows 2000/98
    I want to customize the Oracle application's forms. How
    can I open the forms source located in the UNIX (middle tier)
    with forms 6i in Windows 2000?
    If I FTP the source forms from UNIX to my working environment
    (windows 2000), the attached library will be lost. How can
    I easily do the development in such situation?
    Thank you very much!!!!!!

    Just remember,
    the binaries will not be compatible. You can open an .fmb file and modify it on windows machine (assuming you are going to use the same version of developer), after the modifications are don on the windows end, you need to move (copy, ftp, your choice) back to Solaris, and recompile the same form on Solaris to generate a binary (.fmx) for that particular platform. If you made modifications on libraries and/or menus of the same application on windows end, you need to do the same thing - recompile it on the unix end to have the related plx and mmx files.

  • How can i open a attachment with the fileextension .note sent from an Ipad

    A friend of mine sent me an email from his Ipad with an attachment which has the extension .note. How can I open this file on my Mac?

    It appears that this extension is related to the ipad app 'notability'. It would have to be exported as a pdf or rtf file to be opened.
    You can do some googling, but might be better if the sender converts the file to something more common and sends again.

  • How can I open the windows file directory in "WHEN-BUTTON-PRESSED" trigger

    Dear All,
    How can I open the windows file directory in “WHEN-BUTTON-PRESSED” trigger?

    Blessan Joseph,
    The solution is dependent on your Forms version and if your applications is traditional Client/Server (CS) (Forms 6i and lower) or web deployed (Forms 6i and higher). For CS, you would use the Get_File_Name() built-in as Faa demonstrated. For Web, you will need to use the WebUtil library function Client_Get_File_Name() as Sarah (OGIR) demonstrated. Both of these functions will return the full path to a file. Note: WebUtil is an external library so it requires you to perform some configuration on your developer client as well as on the Application Server. WebUtil is included with Forms 9i and higher, but you must download it for Forms 6i.
    My requirement is user should able to select windows directory for the output.Do you really need to allow the user to write to a file in the Windows directory? This is very dangerous and you should not allow users or programs to write to the Windows directory. Users should only be able to write files to "User" directories (\My Documents\<Directory name>).
    Craig B-)
    If someone's response is helpful or correct, please mark it accordingly.

  • How can i open my Java aplication...

    Hi everybody!
    I was wondering how can i open my Java Picture Viewer by presing an picture.
    When i am running the program with an argument like this
    --> java JPic <path to picture> its ok.
    But i want to press the image and automaticly open my Java Program.
    How can i do that?
    I have to use a native method?
    The source of my program is here:
    http://aetos.it.teithe.gr/~athoik/myprograms/jpic/jpic.html
    Every help IS ACCEPTABLE AND NECESSARY.

    I find it how it works. Al you need to do is make a script. So by presing a picture with your
    mouse or on shell the program run with the specific picture as input :)
    Cool!!
    ##### For Windos Script .bat ######
    @cd C:\
    @cd "C:\path to program\"
    @java -jar JPic.jar %1
    @pause
    ###### For Linux Script ########
    @cd /where the program is
    @java -jar JPic.jar $1

  • How can I open Adobe Bridge CS6 in high resolution on my MacBook Pro Retina display?

    How can I open Adobe Bridge CS6 in high resolution on my MacBook Pro Retina display? When I click Get Info, the "Open in Low Resolution" box is marked and locked. How can I unmark this box? I currently run 10.9.1. I can open Adobe Photoshop CS6 in high resolution without any problem. Any advice would be much appreciated. Thanks.

    There is no such thing. In CS6 only PS itself is Retina compatible. You would have to use CC for full Retina support.
    Mylenium

  • How can i open file from adobe reader..i already have adobe read

    how can i open file from adobe reader..i already have adobe reader installed and cannot open a
    file and i cannot convert my file into pdf..

    Is the file really a PDF? Where is it? Have you tried opening it from within Reader?

  • HT202879 how can I open a Word document in Pages 09?

    How can I open a Word document using Pages 09 please? I am trying to open Word documents from a CD using both trying to open in Pages, nd dragging and dropping into the Pages icon in the dock. It tells me, every time, thast the document cannot be opened.

    What happens if you open it in TextEdit or LibreOffice [free]?
    Does it open where you got it from?
    Peter

  • How can I open a second window in iTunes?

    When I see some albums in the the iTunes Store I want to check whether I have some of the songs already. The Search function in the Store only refers to the store and not to my Library. So how can I open a second window in iTunes (one with the Store and one with my Library) to make it easier to compare?
    Thanks

    My understanding it that was removed from iTunes recently (I still run iTunes 7.5 from 2007), so no, not unless you downgrade iTunes (which is not easy).  You can send feedback to Apple about reinstating it but I have yet to see Apple reinstate something that appeared to have been deliberately removed from its software, despite vociferous complaints on this forum.
    http://www.apple.com/feedback/itunesapp.html

  • How can I open a cc2014 file in my cs6 version of Indesign ?

    How can I open a cc2014 file in my cs6 version of Indesign ?
    I have several files that has been saved in a cc2014 version and I can't open them in my CS6 version of Indesign.
    I don t have access to anyone who have the cc 2014 version to convert the file.
    How can I do it from my cs6 version?
    THANKS!

    You can't do it from CS6.
    You have to export to IDML from InDesign CC2014 (or whatever the version it was created in) and then open the IDML in the earlier versoin of InDesign.
    All explained in the FAQ on the main forum page.

  • How can I open a project made in 2000 on Final Cut Pro to migrate it to a new version?

    how can I open a project made in late 2000 on Final Cut Pro to migrate it to a new version to finish editing it? files, timeline and unfinished edit are all stored on hard drive since early 2001, with all the original miniDV tapes still in hand

    Do you still have legacy FCP? If you not you need to find someone who will open the project in FCP6.0.6 or later. Export an XML file of the project. Use 7toX to convert it to an XML format that works with FCPX. Import the converted XML file to FCP.

  • How can I open a PDF into an iBooks folder other than PDF folder?

    How can I open a PDF directly into a folder in iBooks other than the PDF folder?  I have different folders made and am currently having to open into the PDF folder and then move to the correct folder. Can I open directly into the needed folder? 

    No, I don't think so. The pdf isn't capable of knowing which folder you would like it to open in – all it knows is that it is a pdf. It's up to you to put it in the appropariate folder.

  • How can i open a PDF bank statement in numbers so that the rows and columns contain properly aligned data from statement?

    how can i open a PDF bank statement in "numbers" so that the rows and columns contain properly aligned data from statement?

    Numbers can store pdfs pages or clippings but does not directly open pdf files.  To get the bank statement into Numbers as a table I would open the bank statment in Preview (or Skim) or some pdf viewer.
    Then hold the option key while selecting a column of data.
    Then copy
    Then switch to numbers and paste the column into a table
    Then repeat for the other columns in the pdf document
    It would be easier (in my opinion) to download the QFX or CSV version from your bank

  • Error message: "Can't open file "[File path, file name].key"

    If I attempt to open any Keynote files, I now get this error message.
    "Can't open file "[File path: file name].key"
    To clarify, the text in the square brackets above would be the file path and then the file name.
    The file then will appear on the screen, but is unresponsive to any clicks or menu commands.
    The files will open successfully on other Macs, so they aren't corrupt.
    Also - I've just checked, and opening Keynote and trying to create a new presentation leads to the same problem: All screen menus / buttons are dead - all I can do is drag the window around the screen.
    I've tried to reinstall Keynote, but this hasn't resolved the problem.
    Is there some corrupt preference file (or similar) that I need to get rid of? Is there an easy way to do a complete uninstall of Keynote so I can try another install? Or is this a symptom of something else?
    All ideas gratefully appreciated!
    Message was edited by: Brendan Donlon

    All the issues I describe in my questions around this time re: Keynote were actually symptoms of a soon-to-die laptop. The Hard Disc was corrupting, and Keynote was the first application to be affected.

Maybe you are looking for

  • Master Data Source Enhancement

    Hi Gurus I have a table in SAP which has customer, Sales Organization, Distribution Channel, Language (which is in EN always) and Customer Sales Text... The Customer Sales Text is maintained at Sales Organization and Distribution Channel level..below

  • Cannot set "'Directory'" (DynamicConfiguration UDF)

    Experts, in my scenario a generic interface (Proxy2Fille) is used, in which file receiver output FileName and Directory are being determined at runtime. this was implemented using udf at graphical message mapping phase. somehow, i am able to put "Fil

  • Screen noise when using an ILO moniter

    We recently purchased a Mac mini and bought a ILO 15" moniter from Walmart to use with this machine. It's fine when you first boot it up but after you open an application the screen starts to get lines accross it and they increase until you can barel

  • Load balancing OHS-OC4J

    Hi there I've 2 servers OAS 10.1.2 with the same kind of installation. First box: OHS + OC4J mod_oc4j.conf: <IfModule mod_oc4j.c> Oc4jSelectMethod roundrobin Oc4jMount /Forms/* instance://ip1:6200, ip2:6200 Second box: OHS + OC4J mod_oc4j.conf: <IfMo

  • I have no window into which to type a url. Also there are no pull-down tabs.. options? tools? etc. Do I need to remove Firefor and RE-install?

    Firefox worked fine yesterday. Now I have no window into which to type a url. Also there are no pull-down tabs.. options? tools? etc. == just now when I started Firefox