namespace hello; interface uses System, System.Reflection, System.Runtime.InteropServices; type Hello = class public class method Main(args: array of String): Integer; end; implementation class method Hello.Main(args: array of String): Integer; var objType: System.Type; shell: Object; param: array of Object; folder: Object; begin objType := System.Type.GetTypeFromProgID("Shell.Application"); shell := Activator.CreateInstance(objType); param := [ 0, "Hello, COM(Oxygene) World!", 0, 36 ]; folder := shell.GetType().InvokeMember( "BrowseForFolder", BindingFlags.InvokeMethod, nil, shell, param ); if folder nil then begin Marshal.ReleaseComObject(folder); end; Marshal.ReleaseComObject(shell); end; end.