🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.api
Article #2944

Using JBuilder 2, JNI, and MFC together

#2944
From: rrubin
Date: Wed, 24 Jun 1998 00:00
18 lines
1533 bytes
Hi folks,

I'm using the JNI to access an MFC extension DLL (MSVC++ 5.0) from a JBuilder
2 application. I've been reasonably successful so far, but when I try to call
MFC functions like AfxMessageBox(), I encounter a crash. I've tried adding
AFX_MANAGE_STATE(AfxGetAppModuleState())at the beginning of my JNI exported
function, but that doesn't solve the problem.  I'm linking my MFC DLL with
java.lib instead of javai.lib since I'm using the 1.2 beta 3 JDK, if that
helps.	Any insight into this problem would be greatly appreciated.

Please forgive me if this message has inadvertently been posted twice.

Thanks,
Richard

-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/   Now offering spam-free web-based newsreading
Technical Details
Message-ID: <6mr0n3$c9t$1@nnrp1.dejanews.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10a146,33fb83ba7ba853a7,start
X-Google-Attributes: gid10a146,public
X-Google-Thread: 113ae9,33fb83ba7ba853a7,start
X-Google-Attributes: gid113ae9,public
X-Google-Thread: 1089d0,33fb83ba7ba853a7,start
X-Google-Attributes: gid1089d0,public
From: rrubin@my-dejanews.com
Subject: Using JBuilder 2, JNI, and MFC together
Date: 1998/06/24
Message-ID: <6mr0n3$c9t$1@nnrp1.dejanews.com>
X-Deja-AN: 365624220
X-Http-User-Agent: Mozilla/4.0 (compatible; MSIE 4.01; Windows NT)
Organization: Deja News - The Leader in Internet Discussion
X-Article-Creation-Date: Wed Jun 24 13:58:58 1998 GMT
Newsgroups: borland.public.jbuilder.java.api,comp.lang.java.help,comp.lang.java.programmer