Computing desk | ||
---|---|---|
< July 16 | << Jun | July | Aug >> | July 18 > |
Welcome to the Wikipedia Computing Reference Desk Archives |
---|
The page you are currently viewing is an archive page. While you can leave answers for any questions shown below, please ask new questions on one of the current reference desk pages. |
I am not exactly new to java, but i could never do stuff with applets properly. I'm currently trying to make an applet for independent research, NOT for homework, and its not working.
When i view the applet on the webpage, it simply shows a gray viewing area. I'm thinking ive done something silly, like added all the components, but failed to "show" them somehow in the paint method?
Either way, here is my source: http://pastebin.com/t1HvR5hb
Any help is greatly appreciated, thank you! 172.163.37.111 (talk) 05:01, 17 July 2012 (UTC)
JFrame
that you create and then do nothing with. You don't use the JFrame
for applets, only for applications (some java programs are written to work either stand-alone or as an applet, and they will make clever use of the main(String[])
and init()
methods to dynamically decide whether to put their content into a JFrame
or into the content pane of a JApplet
). In a JApplet
, you should invoke getContentPane()
directly, and add your UI components to that. BigNate37(T) 06:35, 17 July 2012 (UTC)
init()
method. I didn't go to the trouble of testing it for errors, but it should help get the point across in case I didn't explain it well. BigNate37(T) 06:38, 17 July 2012 (UTC)This helped. However, i now have another issue. The applet does not show if i have the source state a package name. It will say "main (Wrong name main/attractors)" ...... Taking the package off means it works. This is rather annoying as i would like to have a package so that i can make some runnable information in a separate class. How can i do this without this error? 172.162.231.158 (talk) 15:45, 17 July 2012 (UTC)
Issue resolved. I did something silly which resulted in a null pointer. xD 172.162.231.158 (talk) 04:38, 18 July 2012 (UTC)
So I'm editing a Wikipedia page using my IPad and I want to find text, say all instances of a refname. How do I search for text on a webpage when I have no CTRL-F? I know this is a pretty basic question, sorry, I've been using keyboard shortcuts since before they were shortcuts. ;-) Itsmejudith (talk) 17:55, 17 July 2012 (UTC)
I don't want to mess around; I just want to get everything. I recall that the best way to do that is Web2C, but I can't find that in the APT cache. Is there an APT package that installs everything, or do I need to download Web2C and go around APT? --Trovatore (talk) 19:13, 17 July 2012 (UTC)
apt-file
package should be able to tell you that. ¦ Reisio (talk) 22:24, 17 July 2012 (UTC)Has anyone else experienced this? When I browse Facebook on Mozilla Firefox at home late in the evening, everything else works fine, but clicking on photographs usually doesn't do anything. I can't even view my own photographs in my own albums. Sometimes, very infrequently, it works, but usually it doesn't. However, when I browse Facebook at work, clicking on photographs works OK. I also use Mozilla Firefox there, but on Microsoft Windows instead of Linux, thanks to 99.999999% of Finnish IT companies using only Microsoft Windows. Could this have something to do with it? However, I think the reason might not be that, but instead that the Internet tends to be more popular late at night at Eastern European Time than in the middle of the day. JIP | Talk 20:33, 17 July 2012 (UTC)
yum update firefox
than compile the entire browser from the sources and install it by hand. JIP | Talk 20:42, 17 July 2012 (UTC)