Share via


Fax Service and Configuration Extension Interaction

The following diagram shows the interaction between the fax service and a fax extension DLL if the extension DLL exports the FaxExtInitializeConfig function. The numbers in the diagram refer to the event numbers in the table that follows the diagram.

Note

With the exception of Event 1, the numbered events in the following diagram do not imply a sequence of steps or the order in which the function calls must occur. The numbers relate only to the events in the table that follows the diagram.

 

interaction between the fax service and a fax extension dll if the dll exports faxextinitializeconfig

The following table lists the primary events that can occur if you use the fax extension configuration API to retrieve and set fax device configuration data.

Event Description
1 Except in the case of a virtual fax service provider (FSP), the fax service calls the [FaxExtInitializeConfig](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextinitializeconfig) function before it calls the extension's general initialization routine. In the case of a virtual FSP, the fax service calls [FaxDevVirtualDeviceCreation](/previous-versions/windows/desktop/api/FaxDev/nf-faxdev-faxdevvirtualdevicecreation) before it calls FaxExtInitializeConfig. FaxExtInitializeConfig passes pointers to the fax service's callback functions. The extension DLL must store the pointers.
2 To retrieve configuration data, the extension DLL must call the fax service's [FaxExtGetData](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextgetdata) callback function, using the callback function pointer provided by the fax service in Event 1. The fax service allocates any memory required for the data and returns the information to the fax extension.
For more information, see Event 6.
3 To register to receive notifications about configuration data changes, the extension DLL must call the fax service's [FaxExtRegisterForEvents](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextregisterforevents) callback function. (The fax service provides a pointer to this callback function in Event 1.) When you call FaxExtRegisterForEvents, you must supply the pointer to a [FaxExtConfigChange](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextconfigchange) callback routine that you implement. The fax service calls this routine to send notifications to the extension.
For more information, see Event 7.
4 To set configuration data, the extension DLL must call the fax service's [FaxExtSetData](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextsetdata) callback function, using the callback function pointer provided by the fax service in Event 1.
5 To stop receiving notifications about configuration data changes (after registering for notifications as outlined in Event 3), the extension DLL can unregister by calling the fax service's [FaxExtUnregisterForEvents](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextunregisterforevents) callback function, using the callback function pointer provided by the fax service in Event 1.
6 If the extension DLL previously called the [FaxExtGetData](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextgetdata) function, the extension must deallocate the data after it processes the data returned in Event 2.
[!Note]
The extension must deallocate the data by calling the fax service's [FaxExtFreeBuffer](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextfreebuffer) callback function, using the callback function pointer provided by the fax service in Event 1.

7 If the extension DLL previously registered to receive notifications about configuration data changes (as in Event 3), the fax service notifies the extension by calling the extension's [FaxExtConfigChange](/previous-versions/windows/desktop/api/FaxExt/nf-faxext-faxextconfigchange) callback function.

 

Examples of instances when the fax service might send configuration change notifications include when another extension sets a new value for a device and data GUID for which the extension DLL has already set a value.