First Initial context factory has to be created with a hashtable as the
argument,
In the hash table u have 2 use Application Server specific properties to do
look up for the Bean
----- Original Message -----
From: Vinod <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, September 12, 2000 10:49 AM
Subject: Re: has anyone ever tried to look up a EJB from a JSP


> Yes, You can look up from Jsp, here is the sample code..
>
>
> <%
>
>
>         Context ctx = null;
>         Bean bn = null;
>         try {
>         ctx = new InitialContext();
>
>         BeanHome home = (BeanHome) ctx.lookup("BeanHome");
>         bn =  home.create();
>
>         bn.beanfunction();
>
> %>
>
> -----Original Message-----
> From: Krishnaraj, Muralidharan (CTS) [mailto:[EMAIL PROTECTED]]
> Sent: 12 September 2000 15:12
> To: [EMAIL PROTECTED]
> Subject: has anyone ever tried to look up a EJB from a JSP
>
>
> hai
>   I want to look up a bean from a jsp .
>   I read from the ED ROMAN book that current version of JSP doesnot
support
> lookin up , but in the EJB spec he has explained
>   this  look up by writing a java bean class in which all the look up code
> is written and he is including the bean class using a <usebean> tag . I
> tried this but it is not working can any one give me a suggestion if
> possible a example
>
> Thanks in advance
> Thanks and Regards
>
> Krishnaraj Muralidharan
>
>
> This e-mail and any files transmitted with it are for the sole use of the
> intended recipient(s) and may contain confidential and privileged
> information.
> If you are not the intended recipient, please contact the sender by reply
> e-mail and destroy all copies of the original message.
> Any unauthorised review, use, disclosure, dissemination, forwarding,
> printing or copying of this email or any action taken in reliance on this
> e-mail is strictly
> prohibited and may be unlawful.
>
>                 Visit us at http://www.cognizant.com
>
>
===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
> of the message "signoff EJB-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>
>
===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
> of the message "signoff EJB-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>
>

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to