Option Infer On Imports System Imports System.Runtime.InteropServices Namespace Examples Friend Class Program <STAThread> Shared Sub Main(ByVal args() As String) Dim application As DesignManager.Application = Nothing Dim insight As DesignManager.Insight = Nothing Try application = New DesignManager.Application() insight = CType(application.Insight, DesignManager.Insight) Catch ex As System.Exception Console.WriteLine(ex) End Try End Sub End Class End Namespace
using System; using System.Runtime.InteropServices; namespace Examples { class Program { [STAThread] static void Main(string[] args) { DesignManager.Application application = null; DesignManager.Insight insight = null; try { application = new DesignManager.Application(); insight = (DesignManager.Insight)application.Insight; } catch (System.Exception ex) { Console.WriteLine(ex); } } } }