Tobi,
thank you for picking this up. I didn’t wanted to post critics, I just wanted to ask for help. J
I am not sure what you mean with I have to usw WinDef.SHORT: Where to put that? You mean replace the short parameter by SHORT instance?
Regards
Markus
--
You received this message because you are subscribed to a topic in the Google Groups "Java Native Access" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jna-users/1Yhz0AprL7g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jna-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
The COM interface says that it wants and int for that parameter.
To unsubscribe from this group and stop receiving emails from it, send an email to jna-users+unsubscribe@googlegroups.com.
The question is: Change it to what? As I described, when using the right parameters (taken from JACOB) then JNA still is failing when doing the invocation. L
Von: jna-...@googlegroups.com [mailto:jna-...@googlegroups.com] Im Auftrag von wolf....@gmx.net
Gesendet: Freitag, 23. Mai 2014 13:47
An: jna-...@googlegroups.com
Betreff: Re: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
ok, if the code generation is wrong you need to change it manually. Should be no problem at all.
Am Freitag, 23. Mai 2014 13:39:45 UTC+2 schrieb Markus Karg:
The COM interface says that it wants and int for that parameter.
Von: jna-...@googlegroups.com [mailto:jna-...@googlegroups.com] Im Auftrag von wolf....@gmx.net
Gesendet: Mittwoch, 21. Mai 2014 10:09
An: jna-...@googlegroups.com
Betreff: Re: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
I`m not sure if that line is necessary. I don`t know your COM interface, but maybe the hwnd can be given into it directly.
long h = Pointer.nativeValue(hWnd.getPointer());
--
Tobias,
if I understand correctly this means that the COM Server must be changed. This is forbidden, as that interface must stay unchange for backwards compatibility with lots of other existing software.
Regards
Markus
Tobi,
have a relaxed time in italy! :-)
The VM we did the TeamViewer debugging session within is powered by VMware on a 64 Bit host. It runs 64 Bit Windows 7 Pro. Eclipse is Kepler on Java 8 (64 Bit). The COM Server is 32 Bit.
CU on Monday
-Markus
I cannot compile SimpleObject.java as it invokes a constructor of COMEarlyBindingObject which is not existing in JNA 4.1.0. Maybe you are using a non-published branch of JNA allowing to pass a String instead of a CSID?
--
You received this message because you are subscribed to a topic in the Google Groups "Java Native Access" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jna-users/1Yhz0AprL7g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jna-users+...@googlegroups.com.
Hi Markus,yes I`ve added a new constructor for using a progID. Just change that back to the CLSID. its is more or less the same.
Betreff: AW: Re: RE: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
I cannot compile SimpleObject.java as it invokes a constructor of COMEarlyBindingObject which is not existing in JNA 4.1.0. Maybe you are using a non-published branch of JNA allowing to pass a String instead of a CSID?
Von: jna-...@googlegroups.com [mailto:jna-users@googlegroups.com] Im Auftrag von Tobias Wolf
Gesendet: Mittwoch, 4. Juni 2014 09:02
An: jna-...@googlegroups.com
Betreff: Aw: Re: RE: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
Hi Markus,
I send you my COM Server as attachment. Don`t forget to register the COM server with:
regsvr32 JNA_COM.dll
Gesendet: Mittwoch, 04. Juni 2014 um 08:40 Uhr
Von: "Markus Karg" <ka...@quipsy.de>
An: jna-...@googlegroups.com
Betreff: Re: RE: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
Don't want to bother, but can you please send me your COM-Server binary so I can try to repeat your tests in my VM? :-)
--
You received this message because you are subscribed to the Google Groups "Java Native Access" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jna-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "Java Native Access" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jna-users/1Yhz0AprL7g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jna-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Java Native Access" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jna-users+unsubscribe@googlegroups.com.
Done. Here is the result:
Exception in thread "main" com.sun.jna.platform.win32.COM.COMException: Typkonflikt. (puArgErr=1)
at com.sun.jna.platform.win32.COM.COMUtils.checkRC(COMUtils.java:116)
at com.sun.jna.platform.win32.COM.COMBindingBaseObject.oleMethod(COMBindingBaseObject.java:267)
at myPackage.atldllcomserverlib.SimpleObject.InitServer(SimpleObject.java:63)
at myPackage.atldllcomserverlib.SimpleObject.main(SimpleObject.java:77)
ProcessorArchitecture: win64
COM is running 32bit.
Looks rather similar that with my own COM-Server, so I suspect there is some difference within COM between your Win7 and mine.
Regards
-Markus
Von: jna-...@googlegroups.com [mailto:jna-...@googlegroups.com] Im Auftrag von wolf....@gmx.net
Gesendet: Donnerstag, 5. Juni 2014 09:41
An: jna-...@googlegroups.com
Betreff: Re: AW: Re: RE: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
just replace the ctx with that code below
public static final CLSID SIMPLEOBJECT_CLSID = new CLSID("{92FCF37F-F6C7-4F8A-AA09-1A14BA118084}");
public SimpleObject() {
super(SIMPLEOBJECT_CLSID, false, WTypes.CLSCTX_SERVER);
}
Am Donnerstag, 5. Juni 2014 09:10:12 UTC+2 schrieb Tobias Wolf:
Hi Markus,
yes I`ve added a new constructor for using a progID. Just change that back to the CLSID. its is more or less the same.
Gesendet: Donnerstag, 05. Juni 2014 um 08:19 Uhr
Von: "Markus Karg" <ka...@quipsy.de>
An: "jna-...@googlegroups.com" <jna-...@googlegroups.com>
Betreff: AW: Re: RE: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
I cannot compile SimpleObject.java as it invokes a constructor of COMEarlyBindingObject which is not existing in JNA 4.1.0. Maybe you are using a non-published branch of JNA allowing to pass a String instead of a CSID?
Von: jna-...@googlegroups.com [mailto:jna-...@googlegroups.com] Im Auftrag von Tobias Wolf
Gesendet: Mittwoch, 4. Juni 2014 09:02
An: jna-...@googlegroups.com
Betreff: Aw: Re: RE: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
Hi Markus,
I send you my COM Server as attachment. Don`t forget to register the COM server with:
regsvr32 JNA_COM.dll
Gesendet: Mittwoch, 04. Juni 2014 um 08:40 Uhr
Von: "Markus Karg" <ka...@quipsy.de>
An: jna-...@googlegroups.com
Betreff: Re: RE: Can not set com.sun.jna.platform.win32.WinDef$SHORT field com.sun.jna.platform.win32.Variant$VARIANT$_VARIANT$__VARIANT.iVal to java.lang.Short
Don't want to bother, but can you please send me your COM-Server binary so I can try to repeat your tests in my VM? :-)
--
You received this message because you are subscribed to the Google Groups "Java Native Access" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jna-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "Java Native Access" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jna-users/1Yhz0AprL7g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jna-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Java Native Access" group.
To unsubscribe from this group and stop receiving emails from it, send an email to jna-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to a topic in the Google Groups "Java Native Access" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/jna-users/1Yhz0AprL7g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to jna-users+...@googlegroups.com.
What „native Code“ do you mean?
Hell… Do you think this is really necessary? I mean, I really would love to help to improve JNA COM and get all that running, but I actually am not so deep in C++ / COM that I think I can debug anything or even see a bug if its right on my screen. ;-)
Maybe it is best if we team up, so you can debug on my VM by TeamViewer?
If you like we can do that, but I do not own that Microsoft software you talked about.