How the heck do i display an image in jeditorpane???

Ive search the site and i still cant find any info on how to enter an image into jeditorpane, i know its possible cause i can display web pages in it without a hitch
cheers-

earljavadev's answer was pretty straightforward.
it's only one way to do it, but just follow his directions to get the code at the bottom. there are other insert*** methods that you can call to get content into the document as well.
// *** code folows ***
Document doc = myJEditorPane.getDocument();
String imageFile = "myImage.png"; // get the image from a filechooser if you want
Style style = doc.addStyle("StyleName", null); // ignored
StyleConstants.setIcon(style, new ImageIcon(imageFile));
try
doc.insertString(doc.getLength(),
"ignored text", style);
catch (BadLocationException ble)
System.err.println("BadLocationException: " + ble);

Similar Messages

  • TS3648 great, but my MBA did not come with an installion disc, only a tiny jump drive that is not recognized by windows; and I can't get the contents of that burned to a DVD either. So how the heck do I get the drivers into Windows 7? My MBA has bootcamp

    great, but my MBA did not come with an installion disc, only a tiny jump drive that is not recognized by windows; and I can't get the contents of that burned to a DVD either. So how the heck do I get the drivers into Windows 7? My MBA has bootcamp 3.0.4.

    Here's what I get:
    lo0: flags=8049<UP,LOOPBACK,RUNNING,MULTICAST> mtu 16384
    inet 127.0.0.1 netmask 0xff000000
    inet6 ::1 prefixlen 128
    inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
    gif0: flags=8010<POINTOPOINT,MULTICAST> mtu 1280
    stf0: flags=0 mtu 1280
    en0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
    ether 00:11:24:7d:e7:1e
    media: autoselect (none) status: inactive
    supported media: none autoselect 10baseT/UTP <half-duplex> 10baseT/UTP <full-duplex> 10baseT/UTP <full-duplex,hw-loopback> 100baseTX <half-duplex> 100baseTX <full-duplex> 100baseTX <full-duplex,hw-loopback>
    en1: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 1500
    inet6 fe80::211:24ff:fe28:2e71%en1 prefixlen 64 scopeid 0x5
    inet 169.254.115.141 netmask 0xffff0000 broadcast 169.254.255.255
    ether 00:11:24:28:2e:71
    media: autoselect status: active
    supported media: autoselect
    fw0: flags=8863<UP,BROADCAST,SMART,RUNNING,SIMPLEX,MULTICAST> mtu 2030
    lladdr 00:11:24:ff:fe:7d:e7:1e
    media: autoselect <full-duplex> status: inactive
    supported media: autoselect <full-duplex>

  • How the heck do i get more ring tones on my phone i purchase them and they go into my music but not ring tones any one no how i can put more on my ringtones plz n ty

    how the heck do i get more ring tones on my phone i purchase them and they go into my music but not ring tones any one no how i can put more on my ringtones plz n ty

    Make sure your own music files are saved in the proper folder (Digital sounds) whether in your memory card or the phone memory, the location should still be:
    Sound Clips > Digital Sounds.
    If your songs/mp3s are saved anywhere else, it will not show up as a selectable ringing tone.
    You can move your songs through File Manager on your phone if they are in the wrong location (Options > Move to folder).
    Hope that clarifies it for you.
    "Try not. Do or do not, there is no try."
    If you found someone's comments helpful or like what that person has to say, please give some Kudos to the post!

  • HT1338 i need to install OS X 10.6.8 or newer.. I have 10.5.8, how the heck do I get 10.6.8 on my macbook pro

    i need to install OS X 10.6.8 or newer.. I have 10.5.8, how the heck do I get 10.6.8 on my macbook pro

    Buy the install DVD for Snow Leopard from Apple
    Allan

  • HT1657 i rented the twilight movie, how the heck do i watch it. it doesnt show up anywhere!! but says i rented it . i did it yesterday. help !!i am so frustrated!!

    i rented the twilight  movie, how the heck do i watch it. it doesnt show up in my library but says i have it rented.

    Go to your music library on itunes, click on the box in the top-left corner of your window that says Music, once you do this there will be an option to click on movies, click on it, and then there will be a little bubble near the top of your window that says rented, click on the bubble, and that will take you to your rented library.
    Note: For itunes 11.0.1 and up.

  • HOW THE HECK DO I USE SAFARI WITHOUT WI FI?????????????? PLEASE HELP ME !!!

    HOW THE HECK DO I USE SAFARI WITHOUT WI FI?????????????? PLEASE HELP ME !!!

    HOW THE HECK DO I USE SAFARI WITHOUT WI FI?????????????? PLEASE HELP ME
    You can't. Safari is an Internet browser and therefore requires a connection to the internet. The only way to connect an iPod touch to the internet, for any purpose, is via WiFi.
    By the way, your capslock and ? keys appear to be stuck - you might want to get them looked at.

  • How the heck did this guy draw with his pencil 3d extruded?

    In the following video Mr. Smith first extrudes some text. Then about 40 seconds in he takes his pencil and draws a line and it's automatically extruded. How the heck did he do that? It looks like it's extruded just as soon as he releases his click. Am I just missing that he's doing "shift-control-e" to apply the same 3d effect immediately to his line? Sure seems like he didn't have to do that.. I can see in the Appearance panel that there is "no selection", but that 3d extrude effect is shown there.
    http://www.adobe.com/designcenter/video_workshop/?id=vid0053

    Understand also: Effects (including 3D Effect) can be applied at the Group or Layer level; not only at the object level. So you can "draw into" a Group in Isolation Mode or "draw onto" a Layer that has 3D Effect applied. In that way, When you do, the various objects you draw not only have the same 3D Effect, but share the same 3D Effect; so they share the same perspective.
    JET

  • How the heck do I back up my hard drive?!

    Sorry if this question gets asked every week, but I searched the "Tiger" forums and still can't figure this out.
    I've owned an iMac since last August but haven't used it much, so I have no after-market software and very little data on it. Unfortunately, the little bit of data I have is every family photo we've taken since last August (on iPhoto) and given the fact that it's a PITA to sync those files with my wife's Dell, I really need to start backing up on a regular basis. In addition, the guys at the "Genius Bar" at my local Apple store tell me there's a defect in the hardware, and advise me to back up my computer before I give it to them to fix.
    Before buying this Apple, I owned several Windows-based PCs. Windows had a utility that would back up the whole computer, and ordinary data backups were fast and easy. The "geniuses" tell me there's no such utility in my version of OS-X, and that I need to buy an external drive and install the third-party software that comes with the drive.
    Okay, I'm sitting down, give it to me straight:
    (1) What's the easiest way for me to back up all the data on my computer, and can I back it up onto one or more CDs? I find it hard to believe that Apple's OS doesn't have a utility that Windows has had for a decade or so, and that I need to buy more hardware and software after purchasing this iMac that costs about twice as much as a Dell with more speed and memory.
    (2) Given that I'll never add software to this machine (other than NeoOffice), do I need to back up anything but data, ever? I have the CDs that came with my iMac, so do I need a bootable copy of my whole hard drive?
    Regards,
    John

    BDAqua wrote:
    It is a simple process, you just chose the wrong HD, the ones with the One-Button touch features, and/or require installing any Software to use are just not good, we just need a Simple Firewire drive to make it simple!
    Yes, it's funny, I just had a couple of hours to think about the last questions I posted, and I realized that "KISS" is all I can handle. All I want (all I can handle, really) is a very simple process for backing up data, nothing more.
    So it looks like I have two things I need to clarify: hardware and software.
    As far as hardware goes, all I'm looking for is something that plugs into the computer like a "thumb drive," but that holds much more data and can transfer it much more quickly. Is that what you mean by a "Simple Firewire drive"? I've looked at the devices on the web page that you linked to, but I can't figure out what the heck they are. Do you remember the first time you looked under the hood of a car, maybe when you were seven or eight years old, and you had no idea what all those hoses and wires and metal things were? Well, that's what it's like for me when I look at that web page.
    Now the software part. I used to own a Windows computer at home and still use one at work. I can move and copy files easily on those machines. And I've copied some files from this iMac to my wife's Windows computer via a thumb drive. No problem. But then I read the article at the link that Japamac posted, and I feel like I have no idea what to do.
    If you actually read the from beginning to end, it doesn't tell you how to do what it recommends, which is to back up the entire <user> folder:
    http://computing.fandm.edu/training/mac/backup.php
    First it talks about backing up the entire <user> folder, but before the article describes how to do that, it skips ahead to a discussion of the limitations on the storage size of CD media and never gets back to telling the reader how to back up the entire <user> folder. Near the end of the article, in the middle of a discussion of how to back up onto an iPod, the article says to "locate and simply drag the data you want to backup from its parent location to the disc volume window." Two problems here: (1) what about backing up ALL the data in the <user> folder; and (2) how do I know that dragging will "copy" rather than "cut"? The last thing I want to do is cut the <user> folder off my hard drive and dump it somewhere else!
    At this point, I can't believe people keep saying that Apple computers are more user-friendly than Windows computers. On Windows, this would be a piece of cake to do with the pull-down menus on the mouse: (1) select the <user> folder with one left-click of the mouse; (2) right-click to "copy;" (3) move the cursor to the storage drive; (4) left-click to select it; and (5) right-click to "paste." Done.
    Please help. All I want to do is find a simple way to back up my data onto an external drive.
    Regards,
    John

  • HT1414 how the heck do you update software on Ipad2 ,their is no freakinmg apple menu with system preferences as suggested by support,re updated a gbame app Texas Holdem and lost game,deleted it and re downloaded game had no effect as all the other sugges

    how thje heck do you update software on IPSDF2 ,as instructed to do by support Re Problem with Texas Holdem Game app,when I updated game I lost iot,an d all atytem,pts thus far except callimng direct to support,anmd updating software was tried.. Support says go to Apple menu,,their is no apple menu with preferences...I tried for hours to locate menu with no avaiilm...

    They're probably telling you instructions based on a computer not an iPad. Different operating systems.
    What you an run on the iPad comes from the app store, and that's where you to go update it. Tap on your app store icon, go to the updates tab and you'll see any applicable updates to your device.

  • How the heck can I delete albums and artists out of Your Music?!?!?!?

    I had asked elsewhere about how to delete stuff out of "Your Music" and was told that from the 3 dots in the upper right of the app screen I would get a "Remove" option.
    BUT.
    1) That option is simply not there all the time. I cannot figure out any rhyme or reason as to why or why not-it seems maybe I can't remove artists, only albums? (But then, I don't see any way to view just albums by an artist...). Maybe it's only items I have played that I can remove? That rule didn't really seem to work either. Some albums/artists I can "remove" but not others, they simply don't show the option, not even greyed out. What the heck is going on?!?!? (These items are NOT in playlists, I hardly use playlists).
    2) Even when I can "Remove" that stuff still appears in the "Your Music" list. So what the heck am I removing? Not the music, as I don't download for offline listening any more. How can I get this stuff totally out of the list? (Yeah, I supposed I could remove and reinstall the entire app, but that seems ridiculous to be doing that periodically)
    I just want to parse the list down to stuff I want to listen to in the future-not junk I already heard, not my kids stuff she sticks in there sometimes. It is really bugging me that I can't clear out this old stuff!Help! Or maybe I should say HELLp!!!

    Hi,
    I will do my best to help you!
    To remove a album follow these steps:
    Open Spotify and go to the "Album view"
    Open the album that you want to remove.
    Scroll all the way up (so that you see the cover).
    Press the "saved"-button so it says "save" instead. 
    Finished.
    Hope this helped. :)

  • Spell Check in New Forums- How The Heck does it work?

    Can somebody please tell me how the spell check works in this new forum format? I click on the abc icon and it does nothing. I do a two finger click on a word that is misspelled and it give me Insert Options. I really like the new format but hate the spell check. Can anyone offer advise? Thanks.

    The built-in ASC spell checker is -- to put it kindly -- quirky. First, you must turn it on using the 'abc' tool on the right in the editor toolbar. (When it's on, it highlights.) But it won't stay turned on if you click on the tool before you enter any text -- it will just tell you that no misspellings were found & won't stay on. It also sometimes fails to check the last word if followed by a space. You can tell it to ignore misspellings, but you can't tell it to learn words because the spell-checking dictionary is actually on the servers running the site, not on your Mac or PC.
    But from your remarks, you probably aren't even using the built-in checker. Instead, I suspect you are trying to use the far superior system-wide one built into OS X. The problem with that is the ASC editing tools are powered by Javascript supplied by the Jive SBS software running the site. Because that is platform independent it doesn't know anything about OS X's contextual menu (which includes suggestions for misspellings, the Dictionary lookup, & so on).
    So to make a long story short, what happens when you try to right click on a word the OS X checker has underlined in red, instead you get the Javascript's response to a right click, which brings up the editor's insert/alignment popup menu instead of the OS X contextual menu.
    The solution is to control click on the word -- believe it or not, within the ASC editor window a right click & a control click are not the same thing! You literally have to hold down the control key on the keyboard when you click to bypass the Javascript's right click response.
    To make things that much more confusing, this only applies if the pointer is not over empty space in the editor window, which in this case excludes lines that have any text on them, including invisible text like spaces or returns. (To see what I mean, drag the tab at the bottom right of the editor window down so there is a lot of empty space below what you have typed. In this empty area, right & control clicks both bring up the OS X contextual menu, but anywhere in the text you have typed, they behave differently.)
    In short, the problem is not that Apple has changed how the buttons or clicks work, it is that the new software that runs the site (not developed by Apple) does.
    Hope this helps.

  • How the heck to stop Illustrator from logging each session?

    Each time I open Illustrator CC a log builds up into the c:\Users\USERNAME\AppData\Roaming\Adobe\Logs\AIPerformance.log file.
    Now it's over 600MB in size. This is not good for my SSD!!!
    So please tell me how the hell to stop this stupid debugging process or whatever the hell is it!

    ...or whatever the hell is it...
    My guess is that it's part and parcel of Adobe's propensity to exploit your computing and connection resources for its marketing "research" purposes every time it "phones home" as you use the software. Even before the Captive Cloud there was a stink regarding Adobe's programs "phoning home" each time the stupid "quick start" screens launched.
    I sympathize, but beyond the guess as to what it's for, can't offer any suggestion for disabling it; I don't (and won't) rent software, so CS6 is where it stops for me. Directly because of the rent-only scheme, I've not even installed Illustrator on my Surface Pro; and I've just installed a SSD as the C:// drive on my primary desktop, so I'm in full agreement with you regarding keeping unnecessary (to ME) clutter to a jealously-guarded minimum.
    JET

  • Super mad!!! Security questions are super old! how the heck could I remember the answers??!!

    I am super mad!! I have a new computer, got a new ipod and just added $85 to my Itunes account to buy music and I know my Apple ID and Password yet it tells me after I add all the money I need to remember super old security questions from years ago before I can use that money!!!
    I cant remember them and now it locked me out of even trying!! If I use my apple ID and my apple ID password why the heck would it want me to answer security questions to purchase music??? Especially since it allowed me to add a lot of money right before!!??

    You will have to try to recover the password or contact Apple for help.
    https://iforgot.apple.com/
    IF you still cannot recover it, contact Apple according to the instructions here.
    Apple ID: Contacting Apple for help with Apple ID account security - Apple Support

  • KM Doc iView-How the content can be displayed in detailed navigation area

    Hi Experts,
    I have doubt related with KM Document iView.
    I have created a HTML page in KM, which will hold 2 links. Give names to these links and href as follows.
    Link1: http://<host>:<port>/irj/portal/*
    Link2: http://<host>:<port>/irj/portal/*
    I have created KM Document iView (ABC) and provided path to document of above HTML page.
    Then I opened my role, created folder inside, and added KM Document iView (ABC). Then I opened the properties of this iView in role and change the property, Initial state as Open,
    I had then expected that the KM document iView (ABC) content Link1 and Link2 to appear in detail navigation area.
    It is not happening. Can you please let me know what is going wrong here
    In other words can you please let me know how I can ensure that
    Link1 Link2 should appear in detailed navigation area side by side.
    Thanks

    Hi Frank,
    Thanks. But this has already been implemented in one project. I have seen this. In that project the detailed navigation area looks like as shown below. The image link and iview link appear in one line
    'jpg image1' 'iviewLink1'
    'jpg image2' 'iviewLink2'
    'jpg image3' 'iviewLink3'
    'jpg image4' 'iviewLink4'
    When the user clicks on jpg image, one iview gets open. When user clicks on iview link other iview gets open.
    I tried a lot. But, I am unable to do this.
    Can it be done using custom PAR file or Visual composer?
    Will appreciate if you can help.
    Thanks
    Brian

  • T430s Error in how the Power Manager icon displays in system tray at bottom of screen

    The icon for the Power Manager in the Windows system tray in the bottom right area of the screen is cut off.    It's basically displaying itself too low on the system bar.  Please see picture attached:
    Does anyone know how to fix this?  I've tried updating to the latest version of Power Manager (v 6.40) but that didn't help.  I'm running Windows 7 Professional 64-bit.
    Thanks.

    Hi, wesaturn
    Have you tried updating all other driver updates available for your system, such as the BIOS and video drivers? They can all be found here if not. 
    Also, how long has this been occurring? And has it ever displayed properly?
    Best,
    Adam
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution!" This will help the rest of the community with similar issues identify the verified solution and benefit from it.

Maybe you are looking for

  • Can I share one iPhoto library with all the users in my iMac?

    I moved the library to the shared folder and gave it 775 permissions but when I try opening it with the second users it asks if I want to fix permissions. I click OK and after a while it tells me it is locked... which kind of tells me I won't be able

  • Only certain sequences can use External DV device to play back/preview?

    Hi there, I'm still working on understanding this HD workflow... Using an HMC40 avccam I shot some PH720 60P footage.  After importing to Premiere Pro CS5 I created a timeline following the guides in http://www.adobe.com/products/creativesuite/produc

  • Wrong Bill-to-Country in  "List of Business Partners"

    Dear Experts, I am facing a strange problem. In the  "List of Business Partners" which pops when we search from the form of Business Partner there are the fields of Bill-to-Country and Ship-to-Country. There are Bps that there is no Bill-to-Country s

  • Efiboot mba can't boot can't repair

    I have a 9 week old MBA. Im quite impressed with Lion (its my first MAC) and the ease of dualbooting. I have Windows 7 dualbooted with Lion using MacDrive to see Macs files. Ever since two days ago, I can no longer boot into "Macintosh HD". It just s

  • Unknown caller, no ID

    On my new Verizon iPhone, if I miss a call from a caller who is not in my contacts, there is no caller ID number displayed in the log; "Unknown Caller" is all that is displayed. My previous Verizon phones showed the originating number, so I expect th