12-03-2011 10:40 AM
Hello everyone,
I have a .net dll wrote in C#. I would like to make use of that .net dll in labview. When I am trying to select the .net constructor in the dll, some of the object in the dll shows that the class contains no public constructor.
The aiballapi.dll comes from the Trek Company used for read the jpg frame from the ai ball camera.
Below is the code in C# connect to the camera.
AiBallConnection
AiBallEngine_engine;
WaveFormat_waveFormat;
IWavePlayer_waveOut;
MemoryStream _ms;
_conn = _engine.AddAiBallConnection("192.168.0.150:8000");
_conn.AddObserver(this);
_conn.Connect();
But when it comes to select add observer_conn.AddObserver(this);
I cannot select the observer .net constructor to add to the _cnn, for the aiballobserver class contains no public constructor.
Below is the code of the aiballobserver from the .net dll.
using System;
namespace AiBallAPI
{
public interface IAiBallObserver
{
void OnConnectionError(AiBallConnectionconn);
void OnConnectionSuccessful(AiBallConnectionconn);
void OnDisconnect(AiBallConnectionconn);
void OnFrame(AiBallConnection conn, byte[] frame);
void OnPCM(AiBallConnection conn, byte[] pcm);
void OnRecordProgress(AiBallConnection conn, intbytesWritten);
}
}
Could you please advice?
Thank you and best regards.
Carol
12-03-2011 04:45 PM
Please do a search first. This question has been asked before. Try what's already been discussed. If nothing works, then post back.
http://forums.ni.com/t5/forums/searchpage/tab/message?q=The+class+contains+no+public+constructor