Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / General / March 2007

Tip: Looking for answers? Try searching our database.

Using Java to write and ActiveX component?

Thread view: 
Björn Ritzl - 06 Mar 2007 10:37 GMT
Hi,

This might be a strange question, but is it possible to write an ActiveX
component using Java? I've seen references to Microsoft's Visual J++. Is
it possible to do using "normal Java"?

I've tried Googling but I'm unable to find any up to date resources. Can
anyone point me in the right direction or simply tell me that it's not
possible?

TIA!

/Björn
Arne Vajhøj - 06 Mar 2007 15:01 GMT
> This might be a strange question, but is it possible to write an ActiveX
> component using Java? I've seen references to Microsoft's Visual J++. Is
[quoted text clipped - 3 lines]
> anyone point me in the right direction or simply tell me that it's not
> possible?

No.

You will need a C++ wrapper and JNI.

Either wrap, find an alternative to using ActiveX or
change language.

Arne
Björn Ritzl - 07 Mar 2007 07:25 GMT
>> This might be a strange question, but is it possible to write an
>> ActiveX component using Java? I've seen references to Microsoft's
[quoted text clipped - 7 lines]
>
> You will need a C++ wrapper and JNI.

Could you point me in the direction of a decent C++ wrapper that would work?

> Either wrap, find an alternative to using ActiveX or
> change language.
>
> Arne

/Björn
Arne Vajhøj - 12 Mar 2007 03:36 GMT
>>> This might be a strange question, but is it possible to write an
>>> ActiveX component using Java? I've seen references to Microsoft's
[quoted text clipped - 10 lines]
> Could you point me in the direction of a decent C++ wrapper that would
> work?

I do not know them, but Google finds:

http://www.ablon.de/de/produkte/overviewstudio.htm
http://www.nevaobject.com/_docs/_java2com/java2com.htm

Arne
Chris Uppal - 12 Mar 2007 19:33 GMT
> > Could you point me in the direction of a decent C++ wrapper that would
> > work?
>
> I do not know them, but Google finds:
>
> http://www.ablon.de/de/produkte/overviewstudio.htm

Java2COM has the necessary low-level tools for COM clients to call Java, but
there are two further challenges that an inplace ActiveX component must meet,
and which it does not seem to address.

One is the layer of convention/design built on top of COM which allows an
(inplace) ActiveX component to mesh with its runtime environment, and be
controlled by it.  You'd have to replicate that layer of software on top of the
Java<->COM bridge (I gather that this is quite tricky, although I know nothing
about it myself, since there are many COM bindings for various languages which
allow you to create COM components, but relatively few, if any, which allow you
to create inplace ActiveX components).

The second is a need for a new implementation of java.awt.Toolkit which draws
its graphics within the bounds of the ActiveX component (assuming that it's
visual) and which interacts (below the AWT API level) with the containing
application.

Neither is /impossible/ (indeed browser/applet integration does something quite
similar, if more limited).  But I don't think that interworking with COM is the
hardest part of the story.

> http://www.nevaobject.com/_docs/_java2com/java2com.htm

I hadn't heard of that before, but the server seems to be down just now, so I
can't comment.

   -- chris
Chris Uppal - 06 Mar 2007 18:13 GMT
> This might be a strange question, but is it possible to write an ActiveX
> component using Java? I've seen references to Microsoft's Visual J++. Is
> it possible to do using "normal Java"?

It might be /possible/ by using a sufficiently advanced COM<->Java bridge[*],
but you'd have to be insane to try it -- or would /become/ insane ;-)

([*] I don't know of any myself, but it's not /technically/ impossible and one
or another of the commercial C<->J bridges may have reached that point.)

   -- chris
Joshua Cranmer - 07 Mar 2007 21:57 GMT
> Hi,
>
[quoted text clipped - 9 lines]
>
> /Björn

Just out of curiosity, why would you wish to write an ActiveX component
using Java?


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.