I decided to try COM library testing_COM.dll created by Matlab Builder NE in VB.net.
Function in Matlab:
function t = test(n)
t=sqrt(n);
end
Registered library in Windows, added reference COM in VB.net and than imported in my vb project:
Imports testing_COM
Created class variable:
Dim calcul As testing_COM.Class1
When I try to call this Matlab function test() :
MsgBox(calcul.test(16))
Instead of result "4", VB.net shows up errors:
Error 1 Argument not specified for parameter 'n' of 'Public Sub test(nargout As Integer, ByRef t As Object, n As Object)'.
Error 2 Argument not specified for parameter 't' of 'Public Sub test(nargout As Integer, ByRef t As Object, n As Object)'.
Does anybody know what is wrong with this function?
Thanks.
Function in Matlab:
function t = test(n)
t=sqrt(n);
end
Registered library in Windows, added reference COM in VB.net and than imported in my vb project:
Imports testing_COM
Created class variable:
Dim calcul As testing_COM.Class1
When I try to call this Matlab function test() :
MsgBox(calcul.test(16))
Instead of result "4", VB.net shows up errors:
Error 1 Argument not specified for parameter 'n' of 'Public Sub test(nargout As Integer, ByRef t As Object, n As Object)'.
Error 2 Argument not specified for parameter 't' of 'Public Sub test(nargout As Integer, ByRef t As Object, n As Object)'.
Does anybody know what is wrong with this function?
Thanks.