maven EJB in Ant built enterprise application, netbeans 7.1.2
===

I have to use a maven built bean in an enterprise app(using Ant). When I try to add it as a java EE module in netbeans, it shows the bean in the list of available modules but fails to add, so when I try inserting code (call enterprise bean) it says "selected bean in not in the same module or enterprise application" 
I tried packaging it as jar as well as ejb in maven pom. Doesn't work either way.
I don't know if its even possible, well I was asked at work to do so, hence the question :) 
It would be great if anybody could solve this.

FYI I am a beginner(student).     