Skip to main content



      Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » SWT COM on X64(SWT Com.OleInitialize not working on x64)
SWT COM on X64 [message #872765] Wed, 16 May 2012 15:26 Go to next message
Eclipse UserFriend
We are using the Com Component of SWT library to initialize a application in Windows.
We use the code
COM.OleInitialize(0);

This code in java works fine for 3.2.2 with java 32 bit. We are trying to migrate to a 64 bit and swt version 3.7.
The code with the combination of 64bit and swt version 3.7 throws an error message saying
SEVERE: org.eclipse.swt.internal.ole.win32.COM.OleInitialize(I)I
java.lang.NoSuchMethodError: org.eclipse.swt.internal.ole.win32.COM.OleInitialize(I)I
Re: SWT COM on X64 [message #873558 is a reply to message #872765] Fri, 18 May 2012 10:26 Go to previous message
Eclipse UserFriend
Method COM.OleInitialize() should be there, but since you're switching
to use 64-bit SWT, its signature changes from COM.OleInitialize(I)I to
COM.OleInitialize(L)I (this is not a portable part of swt because it's
internal). I suspect that your jar was compiled against the 32-bit SWT
3.2.2, and if you re-compile it against 64-bit SWT 3.7 then at runtime
it will attempt look up COM.OleInitialize(L)I instead, which is what the
64-bit swt jar contains.

Grant


On 5/16/2012 3:26 PM, Arvind Arvind S K wrote:
> We are using the Com Component of SWT library to initialize a
> application in Windows.
> We use the code COM.OleInitialize(0);
>
> This code in java works fine for 3.2.2 with java 32 bit. We are trying
> to migrate to a 64 bit and swt version 3.7.
> The code with the combination of 64bit and swt version 3.7 throws an
> error message saying
> SEVERE: org.eclipse.swt.internal.ole.win32.COM.OleInitialize(I)I
> java.lang.NoSuchMethodError:
> org.eclipse.swt.internal.ole.win32.COM.OleInitialize(I)I
Previous Topic:Java Webstart / SWT doens't work on Ubuntu LTS 12.04 ???
Next Topic:Combo and database.
Goto Forum:
  


Current Time: Sat Jul 12 17:07:21 EDT 2025

Powered by FUDForum. Page generated in 0.39821 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top