Developing Windows Clients

When developing Microsoft Windows clients, you interact with the SAS Integrated Object Model (IOM) using the Microsoft Component Object Model (COM). In all the leading programming language products under Windows, and in most Windows applications, COM is the predominant mechanism for software interoperability on the Windows platform.
For the benefit of Windows applications, SAS manifests its IOM as a COM component that uses the automation type system. Microsoft calls this type of COM component an ActiveX component or an OLE Automation server.
Interacting with SAS as an ActiveX component has the following benefits:
  • SAS can be called from a wide variety of programming language environments such as Microsoft Visual Basic (including Visual Basic for Applications and VBScript), Microsoft Visual C++, Borland C++Builder, Visual Basic .NET, and Visual C# .NET, Perl, Borland Delphi, and others.
  • SAS processing can be invoked from the macro language of many popular applications, including those in Microsoft Office.
  • The programming language skills most commonly used to build solutions in the Windows environment can also be applied to developing solutions that involve SAS.
  • Operating system-level security, configuration, and management are the same for SAS as for other applications and systems utilities.
In addition to these standard advantages for integration via COM, the SAS IOM offers a superior capability that is not commonly available to ActiveX components. This function, known as the IOM Bridge for COM, provides the ability to run the server on platforms other than Windows. Using this bridge, a Windows application can request SAS analytical processing for data on a UNIX or z/OS server and receive the results.
The exact interfacing technique used by Windows language products has evolved over the years. The initial approach that was documented in COM supported calls from Visual Basic by using an interface known as IDispatch. With IDispatch, calls into an interface go through a single method (IDispatch:Invoke), and then the appropriate implementation code is looked up at run time. This technique was compatible with early versions of Visual Basic, but was not optimal because of the amount of run-time interpretation that is involved in a method call. To improve performance, subsequent versions of Visual Basic and other languages can use v-table binding to call methods directly. Besides yielding better performance, v-table binding is also the most natural approach for COM calls from C++. The IOM implementation of ActiveX component interfaces uses the dual interface layout that provides both IDispatch and v-table binding. This dual interface gives the best performance from newer language implementations, but still supports the Dispatch technique for client languages (including VBScript and JScript) that use the older approach.
SAS®9 Integration Technologies includes a new client-side component called the object manager. The SAS 8 workspace manager is still supported, but it is recommended that you use the object manager interface in order to take advantage of the new features.
If you are using a SAS Metadata Server, then the object manager enables you to launch and manage objects on other SAS Metadata Servers, SAS Workspace Servers, SAS Stored Process Servers, and SAS OLAP Servers.