开发者

Invisible ActiveX that takes a string

I need to adapt a simple function (let's say) int printText(string) written using an MFC library (this function prints the text on a particular printer whose driver lib is completely developed by MFC), to two applications developed the first in LabView and the second in Java (Eclipse RCP).

I've thought that an ActiveX component is the right choice that could fit well in both applications, but I don't know where to begin.

Is there any one that can guide me in developing this simple ActiveX without dealing with all the flexibilities (i开发者_如何学Python.e complexities) of ActiveX world? My component should be invisible, nothing more than a print method that takes a string (and eventually another init method to initialize the printer).


This greatly depends on the style in ActiveX is written in. Some frameworks can access them and other not. As far as I am aware, the following tools will help you (we use all of them in different contexts):

  • SWT (Has an OLE interface, good for ActiveX controls running in YOUR process)
  • Com4J (Great stuff for working with ActiveX components having its own thread, like remoting Word or Outlook)
  • JNative (Good for calling simple DLL function)
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜