Ok, now it works.
If you are not a newbie, don't read following lines, you'll not learn
anithing!!
I will say what i've got to do to makes my little stupid example works
because
it may help another newbie on jsp,like me.
(i'm on win98 today)
- I'm using the jswdk 1.0
- I've got to at the beginning of jswdk\startserver.bat the line saying
"set JAVA_HOME=d:\jdk1.2\"
- My jsp page was ok at the first time
*********************** html page (thib.jsp) *************
<jsp:useBean id="th" class="thib.thib"
scope="session"/>
<jsp:setProperty name="th" property="*"/>
<html>
<body bgcolor="white">
<%= th.getCount() %>
</body>
</html>
- My java code was wrong (there was to much code :-)
*********************** wrong java code (thib.java) *******
package thib;
public class thib
{
public thib() {}
public int getCount()
{
return 125;
}
public static void main(String args[])
{
new thib();
}
}
what was wrong:
- As Pascal Guilloteau explains me, beans doesn't have any main
method.
*********************** good java code (thib.java) *******
package thib;
public class thib
{
public int getCount()
{
return 125;
}
}
***********************************************************
*****************************************************************
Thibaut Colar
JET Software, Inc.
[EMAIL PROTECTED]
http://www.jetsoftware.com
The Leader in Tools for Online Demonstrations and Training
*****************************************************************
