Solved

Label text doesn't show up in a applet created with Visual J++

Posted on 2002-03-19
2
234 Views
Last Modified: 2006-11-17
The first day I am using the Visual J++. I tried to create an applet with the following code :

<APPLET
class=HelloVisualJ
style="LEFT: 0px; VISIBILITY: visible; TOP: 0px"
name=HelloVisualJ
code=HelloVisualj.class
width=320 height=200>

  <PARAM NAME="foreground" VALUE="FFFFFF">
  <PARAM NAME="background" VALUE="008080">
  <PARAM NAME="label" VALUE="This string was passed from the HTML host."> //<=== Line (A)
</APPLET>

Also, in the code of the applet, I inserted :

  public void paint(Graphics p1)
  {
    p1.drawString("My First Visual J++ Applet", 10,35); //<=== Line (B)
    return;
    }

right under:

    public class HelloVisualJ extends Applet
    {
     
where "HelloVisualJ" is the applet class name.

I was told that the applet should look like:

+--------------------------------------------+
| This string was passed from the HTML host. |
| My First Visual J++ Applet                 |
|                                            |
|                                            |
|                                            |
+--------------------------------------------+

but it showed up in my browser as a blank applet --- both Line (A) and Line (B) were not showing up

Does anyone know what's going on ????????


0
Comment
Question by:shapeless
2 Comments
 
LVL 18

Accepted Solution

by:
bobbit31 earned 50 total points
ID: 6881151
java is case sensitive:

try code=HelloVisualJ.class instead of

code=HelloVisualj.class
 
 
0
 

Author Comment

by:shapeless
ID: 6881268
Shoot !!! That worked !!! :)

Thx a lot.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
map related example 6 59
even odd program using while loop 3 72
passing enum to a method 4 34
Java List 4 33
By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
Introduction This article is the first of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article explains our test automation goals. Then rationale is given for the tools we use to a…
The viewer will learn how to implement Singleton Design Pattern in Java.
This video teaches viewers about errors in exception handling.

735 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question