Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 234876

Summary: [OLE] NPE when loading COM visible .Net WinForms Control
Product: [Eclipse Project] Platform Reporter: Jared Brogni <jared.brogni>
Component: SWTAssignee: Platform-SWT-Inbox <platform-swt-inbox>
Status: CLOSED WONTFIX QA Contact: Felipe Heidrich <eclipse.felipe>
Severity: normal    
Priority: P3 CC: duongn, snorthov
Version: 3.4Keywords: triaged
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard: stalebug
Attachments:
Description Flags
Sample SWT/Java Code being used. none

Description Jared Brogni CLA 2008-05-30 11:51:30 EDT
Created attachment 102893 [details]
Sample SWT/Java Code being used.

When playing around with options for displaying custom .Net WinForms or WPF controls inside a Java based application.  I was working with SWT 3.4M7 and was able to easily load standard COM controls using SWT, but when I tried to load a COM visible .Net WinForms user control, I would encounter the below NPE:

Exception in thread "main" java.lang.NullPointerException
        at org.eclipse.swt.ole.win32.OleClientSite.addObjectReferences(Unknown Source)
        at org.eclipse.swt.ole.win32.OleControlSite.addObjectReferences(Unknown Source)
        at org.eclipse.swt.ole.win32.OleControlSite.<init>(Unknown Source)
        at com.lawson.ComTest.SwtComTest.main(Unknown Source)

When I tried this same display using SWT 3.3.1, it worked fine, but I needed 3.4 for other features we are using within our app.  So I did some looking at changes to this in 3.4 and found the one line change made for SWT Bug 211663.  When I removed this line, and rebuilt SWT, I was again able to load this COM visible .Net Winforms control again.
Comment 1 Felipe Heidrich CLA 2009-08-13 11:01:32 EDT
Your bug has been moved to triage, visit http://www.eclipse.org/swt/triage.php for more info.
Comment 2 Leo Ufimtsev CLA 2017-08-03 12:34:40 EDT
This is a one-off bulk update. (The last one in the triage migration).

Moving bugs from swt-triaged@eclipse to platform-swt-inbox@eclipse.org and adding "triaged" keyword as per new triage process:
https://wiki.eclipse.org/SWT/Devel/Triage

See Bug 518478 for details.

Tag for notification/mail filters:
@TriageBulkUpdate
Comment 3 Eclipse Genie CLA 2020-06-20 11:32:06 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.