MCPcopy Create free account
hub / github.com/HelloBush/Java_MHXYdemo / TestDM

Class TestDM

src/pkgTest/TestDM.java:8–22  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

6import com.jacob.com.Variant;
7
8public class TestDM {
9 public static void main(String args[]){
10 //ComThread.InitSTA();//����ǰJava�̳߳�ʼ��ΪSTA���̵߳�Ԫ(Ӱ��Java-dll����ͨ��)
11
12 //����ActiveXComponentʵ����һ����Į�������
13 ActiveXComponent dm = new ActiveXComponent("dm.dmsoft");
14 //��������&���ö���Dispatch��ʵ��
15 Dispatch dmCom = (Dispatch)dm.getObject();
16 //ͨ��Dispatch���ô�Įdll�е�Ver����������Variant���ܷ��ؽ�����˴�Ϊ�汾��
17 Variant variant = Dispatch.call(dmCom, "Ver");
18 System.out.println(variant.toString());
19
20 ComThread.Release();//��Com���ͷ�Java�߳���Դ
21 }
22}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected