Stretch2 is an extension of the Stretch program. In addition to the capabilities of the Stretch example, Stretch2 illustrates how an application can use DirectDraw on multiple monitors.
Source: (SDK root)\Samples\Multimedia\DDraw\Src\Stretch2
Executable: (SDK root)\Samples\Multimedia\DDraw\Bin
Resize the window to see the bitmap stretch. If you have more than one monitor attached to your computer, the window can be dragged from monitor to monitor.
Look at how the application handles WM_MOVE to detect when the window moves monitors. Also note how it converts from window client coordinates to device coordinates.
Multimon.h contains stub functions that enable the program to run on Windows 95 or Windows NT 4.0.