Vaishali - You have perhaps made a giant leap of faith that utype is
Class String. Do you get a ClassCastException if you do this instead?

      String utype = (String)session.getValue("utype");

Paul Copeland, JOT Object Technologies -- http://www.jotobjects.com

>
> Date:    Sat, 29 Jun 2002 14:37:48 +0530
> From:    "Vaishali S. Pandya" <[EMAIL PROTECTED]>
> Subject: session
>
>       Object utype = session.getValue("utype");
>       if (utype==null || utype.equals("")){
>             utype="0";
>       }
>       if (utype.equals("0") || utype.equals("2")){
>             dis="disabled";
>       }
>       else{
>             dis="~";
>       }
>       out.println("utype = " + utype);
>       out.println("dis = " + dis);
>
> the output is this
> utype = 2
> dis =  ~
> ???????????
> when utype is 2 dis should be disabled but it is not there
> can anyone  make me correct?
>
> Vaishali
> Reliance Ind Ltd
> A'bad
>

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://archives.java.sun.com/jsp-interest.html
 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.jsp
 http://www.jguru.com/faq/index.jsp
 http://www.jspinsider.com

Reply via email to