Ajoy Sharma

Greenhorn
+ Follow
since Feb 24, 2004
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
In last 30 days
0
Forums and Threads

Recent posts by Ajoy Sharma

Hi,
I have installed BDK1.1 and launched it with no problem. But, in the ToolBox, I am missing ExplicitButton, *Button and error log says this:
C:\BDK1.1\jars\buttons.jar: jar load failed: java.lang.Error: java.beans.Introsp
ectionException: Method "actionPerformed" should have argument "ActionPerformedE
vent"
java.lang.Error: java.beans.IntrospectionException: Method "actionPerformed" sho
uld have argument "ActionPerformedEvent"
at sunw.demo.buttons.ExplicitButtonBeanInfo.getEventSetDescriptors(Expli
citButtonBeanInfo.java:60
How do I fix this problem? I downloaded everything from Sun BDK1.1, including the Button.jar ! Thanks a lot of your help !
Anand
Iam facing problem when i am deploying my files on j2ee 1.4 server it give following erroer::
my .tld file and jsp are given below
any body can help me;
mytaglib.tld file:
<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE taglib
PUBLIC "-//Sun Microsystems, Inc.//
DTD JSP Tag Library 1.1//EN"
"http://java.sun.com/j2ee/dtds/
web-jsptaglibrary_1_1.dtd">
<!-- a tag library descriptor -->
<taglib>
<tlibversion>1.0</tlibversion>
<jspversion>1.1</jspversion>
<shortname>first</shortname>
<uri></uri>
<info>A simple tab library for the
examples</info>
<tag>
<name>hello</name>
<tagclass>tags.HelloTag</tagclass>
<bodycontent>empty</bodycontent>
<info>Say Hi</info>
</tag>
</taglib>

MY JSP file :::
<%@ taglib uri="/WEB-INF/mytaglib.tld"
prefix="first" %>
<HTML>
<HEAD>
<TITLE>Hello Tag</TITLE>
</HEAD>
<BODY bgcolor="#ffffcc">
<B>My first tag prints</B>:
<first:hello/>
</BODY>
</HTML>
Error :::
org.apache.jasper.JasperException: Unable to initialize TldLocationsCache: XML parsing error on file /WEB-INF/mytaglib.tld
org.apache.jasper.compiler.TldLocationsCache.init(TldLocationsCache.java:218)
org.apache.jasper.compiler.TldLocationsCache.getLocation(TldLocationsCache.java:188)
org.apache.jasper.JspCompilationContext.getTldLocation(JspCompilationContext.java:515)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:460)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:526)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1617)
org.apache.jasper.compiler.Parser.parse(Parser.java:174)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:244)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:146)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:132)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:245)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:462)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:448)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:551)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:300)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:284)
java.security.AccessController.doPrivileged(Native Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:306)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:200
20 years ago
JSP
thanks for reply
I got it
could tell me why this error is comming in same code:
org.apache.jasper.JasperException: Unable to initialize TldLocationsCache: XML parsing error on file /WEB-INF/mytaglib.tld
20 years ago
JSP
Iam facing problem when i am deploying my files on j2ee 1.4 server it give following erroer::
my .tld file and jsp are given below
any body can help me;

mytaglib.tld file:
<<?xml version="1.0" encoding="ISO-8859-1" ?>
<!DOCTYPE taglib
PUBLIC "-//Sun Microsystems, Inc.//
DTD JSP Tag Library 1.1//EN"
"http://java.sun.com/j2ee/dtds/
web-jsptaglibrary_1_1.dtd">
<!-- a tag library descriptor -->
<taglib>
<tlibversion>1.0</tlibversion>
<jspversion>1.1</jspversion>
<shortname>first</shortname>
<uri></uri>
<info>A simple tab library for the
examples</info>
<tag>
<name>hello</name>
<tagclass>tags.HelloTag</tagclass>
<bodycontent>empty</bodycontent>
<info>Say Hi</info>
</tag>
</taglib>

MY JSP file :::
<%@ taglib uri="/WEB-INF/mytaglib.tld"
prefix="first" %>
<HTML>
<HEAD>
<TITLE>Hello Tag</TITLE>
</HEAD>
<BODY bgcolor="#ffffcc">
<B>My first tag prints</B>:
<first:hello/>
</BODY>
</HTML>
Error :::
org.apache.jasper.JasperException: Unable to initialize TldLocationsCache: XML parsing error on file /WEB-INF/mytaglib.tld: (line 1, col 2)
org.apache.jasper.compiler.TldLocationsCache.init(TldLocationsCache.java:218)
org.apache.jasper.compiler.TldLocationsCache.getLocation(TldLocationsCache.java:188)
org.apache.jasper.JspCompilationContext.getTldLocation(JspCompilationContext.java:515)
org.apache.jasper.compiler.Parser.parseTaglibDirective(Parser.java:460)
org.apache.jasper.compiler.Parser.parseDirective(Parser.java:526)
org.apache.jasper.compiler.Parser.parseElements(Parser.java:1617)
org.apache.jasper.compiler.Parser.parse(Parser.java:174)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:244)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:146)
org.apache.jasper.compiler.ParserController.parse(ParserController.java:132)
org.apache.jasper.compiler.Compiler.generateJava(Compiler.java:245)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:462)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:448)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:551)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:300)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:284)
java.security.AccessController.doPrivileged(Native Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:306)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:200)
20 years ago
JSP
iam sorry .iam unable to understand ur idea. I have already have J2EE application server and JDK \j2sdk1.4.1_02 . in my computer.
and i already set all path all path and class path.
after that plz told me waht i should do to solve this problem.
20 years ago
JSP
hi my J2ee.jar in this C:\Sun\AppServer\lib not in jdk\lib directory .
let me know what i do ??
20 years ago
JSP
My j2ee jdk1.4.2 is not supporting javx package.
i already set all pathh and class path.
anybody can help me.
details are given below ::

C:\AVA\J2EE Programs\JSP\JSPCustomTag>javac ATMTag.java
ATMTag.java:5: package javax.servlet does not exist
import javax.servlet.*;
^<br>
ATMTag.java:6: package javax.servlet.http does not exist
<br>
import javax.servlet.http.*;
<br>
ATMTag.java:18: cannot resolve symbol
symbol : class TagSupport
location: class ATMTag
public class ATMTag extends TagSupport{
<br> ^
ATMTag.java:29: cannot resolve symbol
symbol : class JspTagException
location: class ATMTag
public int doStartTag() throws JspTagException{
<br> ^
ATMTag.java:31: cannot resolve symbol
symbol : class JspWriter
location: class ATMTag
<br> JspWriter out =pageContext.getOut();
^
ATMTag.java:31: cannot resolve symbol
symbol : variable pageContext
location: class ATMTag
<br> JspWriter out =pageContext.getOut();
^
ATMTag.java:56: cannot resolve symbol
symbol : variable pageContext
location: class ATMTag
pageContext.getOut().write(str);
<br> ^
ATMTag.java:60: cannot resolve symbol
symbol : variable EVAL_PAGE
location: class ATMTag
return EVAL_PAGE;
^
8 errors
.
20 years ago
JSP
Hi
iam using J2EETM 1.4 Application Server for dploying and compiling my JSP with beans. Any boduy can help me solve this probelm.
its given error::::
exception
org.apache.jasper.JasperException: Unable to compile class for JSP
No Java compiler was found to compile the generated source for the JSP.
This can usually be solved by copying manually $JAVA_HOME/lib/tools.jar from the JDK
to the common/lib directory of the Tomcat server, followed by a Tomcat restart.
If using an alternate Java compiler, please check its installation and access path.
org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:127)
org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:348)
org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:424)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:464)
org.apache.jasper.compiler.Compiler.compile(Compiler.java:448)
org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:551)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:300)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:324)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:284)
java.security.AccessController.doPrivileged(Native Method)
javax.security.auth.Subject.doAsPrivileged(Subject.java:500)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:306)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:200)

note The full stack trace of the root cause is available in the J2EETM 1.4 Application Server logs.
MY SOURE CODE FOR JSP AND BEAN ARE HERE:
JSP::::
<%-- hello3.jsp --%>
<%@ page import="HelloBean" %>
<jsp:useBean id="hello" class="HelloBean"/>
<jsp:setProperty name="hello" property="*" />
<HTML>
<HEAD><TITLE>Hello</TITLE></HEAD>
<BODY>
<H1>
Hello, <jsp:getProperty name="hello" property="name" />
</H1>
</BODY>
</HTML>

CODE FOR BEAN::
import java.io.*;
import java.util.*;
public class HelloBean {
private String name = "World";

public void setName(String name) {
this.name = name;
}
public String getName() {
return name;
}
}
plz help to solve this Problem
20 years ago
JSP
Hi Naga,
I got ur email ID from Java ranch .com. Iam facing problem to connect JDBC in Oracle database.
The Code is given below. It is complied with out error . when I try to excute it gives error :
java.lang.ClassNotFoundException: oracle.jdbc.oracle.OracleDriver.
could u tell me how can I fix it.

Code for program:

import java.awt.*;
import java.sql.*;
import java.util.*;
import java.math.*;
import java.awt.event.*;
import java.io.*;


public class MakingAStatement
{
public static void main(String[] args)
{
try
{



Class.forName("oracle.jdbc.oracle.OracleDriver") ;


Connection con = DriverManager.getConnection(
"jdbc racle:thin:@meenuanand1:1521:ed05"
,"scott","tiger");





Statement myStatement = con.createStatement();
ResultSet authorResults = myStatement.executeQuery("select cFirst_Name from registration");
}
catch(ClassNotFoundException cnfe)
{
System.out.println(cnfe);
}
catch(SQLException sqle)
{
System.out.println(sqle);
}
}
}