RE : [JAWIN] Jawin @ COM Interop

Franck Casado <[email protected]> Wed, 1 Mar 2006 16:38:31 +0100
Newsgroups gmane.comp.windows.devel.jawin
Message-ID <[email protected]>
 

	Hi,
	      I had some problem too with .net interop objects. It 's a long time ago now, I'm not so sure of myself. My problem was that the object was not really well registered. Be sure that you registered your object with regasm and not regsvr32. If the object is from your own, complier (vs.net) registers it for you, or be carefull to register obejct in your msi project..
	I use Ole32.CoInitialize(COINIT.MULTITHREADED); before calling my object.

	-------- Message d'origine-------- 
	De: Discussion of Java/Win32/COM integration with Jawin de la part de Bob Farnik 
	Date: mer. 1/03/2006 14:45 
	À: [email protected] 
	Cc: 
	Objet: [JAWIN] Jawin @ COM Interop
	
	

	HI,
	I am calling my .net assembly DLL, which is properly registered for COM
	interop from Tomcat 5.5 JSP and JavaBean through jawin 1.2.
	The DLL is registered properly and cI can access its classes, interfaces and
	methods from my VB6 test.
	Invoking it with jawin however is giving an error:
	
	jcom.develop.jawin.COMException: 8000ffff: CoCreateInstance for
	"{64a5179c-ffffaf3b-4e6b-a09e-f4b7efa0ee00}" failed
	 com.develop.jawin.win32.Ole32.CoCreateInstance(Ole32.java:143)
	 com.develop.jawin.win32.Ole32.GetFromProgID(Ole32.java:90)
	 com.develop.jawin.DispatchPtr.<init>(DispatchPtr.java:70)
	 BSCFunctions.IBSCFunctions.<init>(IBSCFunctions.java:38)
	
	
	What is strange is, that thet the class UUID in registry and in the jawin
	stub (generated from my component TLB) is actually:
	64a5179c-af3b-4e6b-a09e-f4b7efa0ee00
	
	I believe it's failing in the following code generated with jcomgen from my TLB:
	   /**
	     * Creates IBSCFunctions Object with CLSID
	     */
	    public IBSCFunctions(GUID ClsID) throws COMException {
	        super(ClsID);
	    }
	
	Anybody knows why this is happening or has an experience with jawin and .NET
	COM Interop?
	
	Thanks,
	Bob