Call EJB with Annotation

S

sss

I am trying to follow this example to figure out how to
call an ejb from the ejb client.

http://java.sun.com/javaee/5/docs/tutorial/doc/EJB2.html

Within the Netbeans, I should be able to execute the following source.

@EJB
private static ConverterBean converterBean;

public static void main(String[] args) {
BigDecimal param = new BigDecimal ("100.00");
BigDecimal amount = converterBean.dollarToYen(param);
System.out.println( amount );
}

however, always gives me error saying ConverterBean can't be found.
Is there any extra step i have to take?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,007
Latest member
obedient dusk

Latest Threads

Top