I have a function that uses Capi and works great with my Windows-based system but won't compile on my HomeTroller SEL Pro under Linux.
Sub Main(ByVal parm As Object)
Dim arrCC() As CAPIControl = Nothing
arrCC = hs.CAPIGetControl(16)
End Sub
When I run this in a Homeseer Event I get an error:
Compiling script /usr/local/HomeSeer/scripts/Conversion Phase 2/FindError2.vb: Value of type 'Object' cannot be converted to 'HomeSeerAPI.CAPI/CAPIControl[]'.
If I comment out the CAPI call it compiles clean.
I have found that mono requires strong typing where Microsoft may be forgiving. Is there a problem with CAPIGetControl returning the correctly typed object? Or am I missing a declaration?
Any advice would be appreciated.
Sub Main(ByVal parm As Object)
Dim arrCC() As CAPIControl = Nothing
arrCC = hs.CAPIGetControl(16)
End Sub
When I run this in a Homeseer Event I get an error:
Compiling script /usr/local/HomeSeer/scripts/Conversion Phase 2/FindError2.vb: Value of type 'Object' cannot be converted to 'HomeSeerAPI.CAPI/CAPIControl[]'.
If I comment out the CAPI call it compiles clean.
I have found that mono requires strong typing where Microsoft may be forgiving. Is there a problem with CAPIGetControl returning the correctly typed object? Or am I missing a declaration?
Any advice would be appreciated.
Comment