srinivas venkat

+ Follow
since Aug 19, 2009
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by srinivas venkat

I have a problem with the working of radio button in jsf. i tried the following code

Here in this case valueChangeListener is not getting exe3cuted.But the radio button is getting selected.

when i add document.form.submit(); to the script valuechangelistener is getting executed but the radio button is not getting selected.
Please advice me on this.
10 years ago
That solved my problem........ i am a beginner started learning servlets and jsps so dont mind if i ask any silly doubts.......Thanks a lot for your help vijitha Kumara ....
12 years ago
thank you very much that solved my problem
12 years ago
Thanks for your help Vijitha Kumara but still the same errors continues package com.example.model doesnot exist ................ i jus changed directories like what you have said...................

i am compiling using the following command

E:\projects\p3>javac -classpath "C:\Program Files\Apache Software Foundation\Tom
cat 5.0\common\lib\servlet-api.jar";"E:\projects\p3\classes\com\example\model";classes:. -d classes src\com\example\web\

and my changed directory structure is
E:\projects\p3\src\com\example\model\ one is compiling and creating .class file at E:\projects\p3\classes\com\example\model\BeerExpert.class

the source code for is

package com.example.web;
import com.example.model.*; ----------error in importing this
import javax.servlet.*;
import javax.servlet.http.*;
import java.util.*;

public class BeerSelect extends HttpServlet
public void doPost(HttpServletRequest request,HttpServletResponse response) throws IOException,ServletException
String c=request.getParameter("color");
BeerExpert be=new BeerExpert();
List result=be.getBrands(c);

PrintWriter out=response.getWriter();
out.println("Beer Selection Advice <br>");

Iterator it=result.iterator();

help me out please
12 years ago
I am studying head first java .In the starting pages of compiling a java file they gave command

%javac -classpath /your path/tomcat/common/lib/
servlet-api.jar -d classes src/

I could actually compile java file through editors but when i try to compile using command prompt i got %javac as not recognized command .if i remove % then i get

javac: invalid flag: Files\Apache
Usage: javac <options> <source files>
use -help for a list of possible options

i gave command as
javac -classpath C:\Program Files\Apache Software Foundation\Tomcat 5.0\common\lib\servlet-api.jar -d classes src\ and i set the correct directory path also

Expecting a reply .
12 years ago
Thanks for your reply

I ill keep my source files in another directory from now onwards

If one of your source files uses any other class file which you compiled those should be accessible in order to compile the class (which is done usually setting a CLASSPATH entry to those packages)

I didnt get your point can i set classpath entry ? how can i solve this problem?
12 years ago
Hi everyone i am newbie to this community.I am reading head first servlets .I got an error showing package com.example.model.*; doesnot exist .........
I set my environmental variable classpath as C:\Program Files\Java\jdk1.6.0\lib\tools.jar;C:\Program Files\Java\jdk1.6.0\lib\dt.jar;.;C:\Program Files\Apache Software Foundation\Tomcat 5.0\common\lib\servlet-api.jar;%CLASSPATH%;

I can compile but i cannot compile file

my directory structure for is C:\Program Files\Apache Software Foundation\Tomcat 5.0\webapps\chanti3\WEB-INF\classes\com\example\web\

my directory structure for is C:\Program Files\Apache Software Foundation\Tomcat 5.0\webapps\chanti3\WEB-INF\classes\com\example\model\

I got the error in the line import com.example.model.*;

can any1 help me?
waiting for your reply

thank you
12 years ago