The following pseudo-code shows how to call a function
(GetComApp.m, described in NET.disableAutoRelease) which returns a COM object. The object,
mainObj of type NetDocTest.MyClass, has a
property, MyApp. Call GetComApp to get a COM object,
and use its readData method.
mainObj = NetDocTest.MyClass;
GetComApp(mainObj);
app = mainObj.MyApp;
app.readData('hello');
% Unlock the COM object
NET.enableAutoRelease(mainObj.MyApp);