Problems with applet - no text in the window
Hi!
I'm trying to learn some java, and I've just done my first applet. The code looks like this:
__
import java.awt.*;
import java.applet.*;
public class MittNamnApplet extends Applet {
Font f;
public void init() {
f = new Font("SansSerif", Font.BOLD, 24);
setBackground(Color.pink);
}
public void pain (Graphics g) {
g.setFont(f);
//g.setColor(Color.blue);
// g.drawString("Habibi", 45,100);
}
}
__
And then I made an html code that looks like this:
<html>
<applet code="MittNamnApplet.class" height=200 width=320>
</applet>
</html>
_
When I run it with appletviewer in Command prompt there is only a pink squre coming up, where is the text? Why? Can someone please help a dummie?
Thanks ;-)

