FaxMan SDK Version 4.7



lParam PFAXDEVICE describes the device that has been added/altered/removed.


This message is sent to your application when a faxmodem is added to or removed from the FaxMan system, or when the status of an installed faxmodem changes. Your application can use this message to keep an up to date display containing a list of all currently installed faxmodems and their status.


When the FaxMan server is loaded, it will send one of these messages for each installed faxmodem. Your application can use the FaxEnumDevices function to force the server to send a list of installed faxmodems, and their current status, at any time.


Note that if the wFlags member of the FAXDEVICE structure is 0, then FaxMan is removing this faxmodem from the faxmodem pool.


The following code illustrates how an application could respond to the FAXMODEMMSG:

// This code simply outputs a string displaying the current

// status of the given faxmodem, including whether it’s sending

// or receiving, the comm port it’s installed on, whether it’s

// configured for sending, receiving, or both, and the

// initialization and reset strings defined for this device.



char  jbuf[100];

LPSTR p1, p2, p3;



 pDev = (FAXDEVICE *)lParam;

 if (!pDev->wFlags) {

  sprintf(jbuf, "Com%d\tDeleting!\r\n", pDev->nPort);


 else {

  if (pDev->wFlags & PORT_SENDING)

p1 = "SENDING";

  else if (pDev->wFlags & PORT_RECEIVING)



p1 = "IDLE";


  if ( (pDev->wFlags & PORT_SEND) && (pDev->wFlags & PORT_RX))

p2 = "Send/Receive";

  else if (pDev->wFlags & PORT_SEND)

p2 = "Send";


p2 = "Receive";


  if (pDev->wFlags & PORT_CLS20)

p3 = "Class 2.0";

  else if (pDev->wFlags & PORT_CLS1)

p3 = "Class 1";


p3 = "Class 2";


  wsprintf(jbuf, "Com%d\t%s\t%s\t%s\t%s\t%s\r\n", \\

pDev->nPort, p1, p2, p3, pDev->szReset, pDev->szInit);







© 2013 Data Techniques, Inc. All Rights Reserved.

Send comments on this topic.