Project

General

Profile

Defect #413

COM PLugin hangs on 64-bit Windows 7

Added by Omar van Galen about 12 years ago. Updated about 12 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Start date:
01/29/2012
Due date:
% Done:

0%

Estimated time:
Browser (if web client):

Description

Hi Patrick,

Thanks a lot for the update on the COM Plugin! I am still having trouble getting it to work though. I have installed it on my machine along with the sample application and the IsJacobInstalled() method returns true. However, when executing the line of code with the call to getNewClientJSCOM("Internet.Application") nothing happens and it never gets to the following line of code. Do you have any idea's? Thanks

Omar van Galen

History

#1

Updated by Patrick Talbot about 12 years ago

  • Status changed from New to In Progress

I think the correct progID for explorer is "InternetExplorer.Application", I just tried here in Win 7 64-bit and it works fine.
Please try with the correct progID and let me know it it works.

Also note that you can only run 64-bit DLLs on 64-bit Java, if you want to run 32-bit DLLs you need to launch Servoy with a 32-bit JVM.

#2

Updated by Omar van Galen about 12 years ago

I used the correct prog id from the solution sample but typed it wrong in the issue. How can I make sure that I am using 64-bit Java? Does this mean that when I use COM I will allways have to build a 32-bit and a 64-bit version? Thx.

#3

Updated by Patrick Talbot about 12 years ago

  • Status changed from In Progress to Closed

To know what version of Java you have installed you can issue:
java -version
on the command line.

This will output something like this (where the version is the one you have):

java version "1.6.0_27" 
Java(TM) SE Runtime Environment (build 1.6.0_27-b07)
Java HotSpot(TM) 64-Bit Server VM (build 20.2-b06, mixed mode)

As you see the 3rd line states that this is 64-bit JVM

Otherwise, you will have something like this:

java version "1.6.0_29" 
Java(TM) SE Runtime Environment (build 1.6.0_29-b11)
Java HotSpot(TM) Client VM (build 20.4-b02, mixed mode, sharing)

In Developer, you can also open the "About Servoy..." menu, click on the "Installation Details" button, go to the last tab "Configuration" and look for the line just below -arch it will states your architecture, which on Windows, will be x86 or x86_64

In Developer's Debug client, you can choose the "Help > About..." menu and the same Java version will be on the 3rd line again.

On a real Smart client (launched from a jnlp URL), show the Java console (you can activate that in your Java preferences panel), the first lines will be the version used by the client.

Now understand that if you use Java 32-bit, you can only use 32-bit binaries, so 32-bit COM components.
If you use Java 64-bit, you can only use 64-bit binaries.
This is a Java limitation, not a COM plugin limitation.

Depending on the components, some exists in 32 and 64-bit version, like Internet Explorer for example, so you dont need to change a thing to use it, whatever the Java version you use.

Some don't have both DLL available, and you're out of luck because in that case: you will have to ask your clients to install a 32-bit JVM (which works fine on a 64-bit OS) to use your app, or use COM on the server side with a Java version installed on the server that matches the architecture of your COM component...
This last option will also require that you write special wrappers to communicate with the server-side COM component though, which can be done in a plugin - like the Firefox plugin I'm working on, and in that case also, you will not be able use COM components with a UI.

Hope this clarifies.

#4

Updated by Omar van Galen about 12 years ago

Hi Patrick,

I got it working at last. Somehow a jacob-1.16-M1-x64.dll of 0 Kb had been installed to my .servoy folder which fooled the plugin into thinking it was there but of course it couldn't be loaded. After deleting it, it was reinstalled automatically and everything worked. I don't know how this came to be, but if anybody else has problems with it, be sure to check the size of the jacob dll.

Omar

Also available in: Atom PDF