怎么在C#中使用外部程序提供的接口
我想使用C#控制电脑上的一个仿真程序plant,plant提供了一个COM接口IRemoteConTrol,我不知怎么在C#使用这个接扣里面的方法
,下面是我写的程序,出错了,说我没引入命名空间,关键是我不知这个接扣在那个命名空间啊,using不会写?怎么改才行呢?
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class NewBehaviourScript : MonoBehaviour ,IRemoteControl{
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
}
}
接口如下:
使用名字是:Tecnomatix.PlantSimulation.RemoteControl.13.0
interface IRemoteControl:IDispatch{
HERESULT NewModel();
HERESULT LoadModel();
}