DBInstallResultHandler
DBInstallResultHandler Install a result handler
#include <DatabaseAccess.h> Data Access Manager
OSErr DBInstallResultHandler( dataType, theHandler,
isSysHandler);
DBType dataType; specifies the data type that the handler is
for
ProcPtr theHandler; is a pointer to the result handler
Boolean isSysHandler; specifies the type of result handler
returns Error Code; 0=no error
The DBInstallResultHandler function installs a result handler for the data
type specified by the dataType parameter. The result handler is then used by
the DBResultsToText function to convert data of the specified type into a
character string.
dataType specifies the data type for which the result handler is being
installed.
theHandler is a pointer to the result handler.
isSysHandler specifies whether the result handler is an application result
handler-to be used only when the DBResultsToText function is
called by the application that installed the result handler-or a
system result handler-to be used by every application running on the
system. If the isSysHandler parameter is TRUE, the result handler is
a system result handler.
When you install an application result handler, it re places any
result handler with the same name previously installed by that
application. Similarly, when you install a system result handler, it
re places any existing system result handler with the same name.
Before you temporarily replace an existing result handler, use the
DBGetResultHandler function to obtain a pointer to the present
handler, and save the present result handler in your application's
private storage. Then you can reinstall the original result handler
when you are finished using the temporary one.
Because an application result handler is used in preference to a
system result handler if both are available, you can temporarily
replace a system result handler for purposes of your application by
installing an application result handler for the same data type. You
can then use the DBRemoveResultHandler function to remove the
application result handler and return to using the system result
handler whenever you wish.
Returns: an operating system Error Code.
noErr (0) No error
rcDBPackNotInited (-813) The InitDBPack function has not yet been called