Index   Commented   Search   About

update

The update command repaints the current frame into the specified device context (DC). Digital-video devices recognize this command.

wsprintf(lpstrCommand, "update %s %s %s", lpszDeviceID, lpszHDC,
lpszFlags);

Parameters

lpszDeviceID

Identifier of an MCI device. This identifier or alias is assigned when the device is opened.

lpszHDC

Handle of a DC. The following table lists device types that recognize the update command and the flags used by each type:

digitalvideo
hdc hdc
hdc hdc at rect
paint hdc hdc

The following table lists the flags that can be specified in the lpszHDC parameter and their meanings:

hdc hdc
Specifies the handle of the DC to paint.
hdc hdc at rect
Specifies the clipping rectangle relative to the client rectangle.
paint hdc hdc
Paints the DC when the application receives a WM_PAINT message intended for a DC.

To specify the handle of the DC, use the string "hdc" followed by an ASCII representation of the handle. The rectangle is specified as X1 Y1 X2 Y2. The coordinates X1 Y1 specify the upper left corner of the rectangle, and the coordinates X2 Y2 specify the width and height.

lpszFlags

Can be "wait", "notify", or both. For digital-video devices, "test" can also be specified. For more information about these flags, see The Wait, Notify, and Test Flags.

Return Values

Returns zero if successful or an error otherwise.

Remarks

The following command updates the entire display window used by the "movie" device. The number 203 is a handle to a DC obtained from the BeginPaint function:

update movie hdc 203

See Also

BeginPaint
, WM_PAINT

Related Links

Software for Delphi and C++ Builder developers
Software for Visual Studio .NET developers
Software for Visual Basic 6 developers
Delphi Tips&Tricks
MegaDetailed.NET

More Online Helps

Win32 Programmer's Reference (win32.hlp)
OLE Programmer's Reference (ole.hlp)
Microsoft Windows Pen API Programmer's Reference (penapi.hlp)
Microsoft Windows Sockets 2 Reference (sock2.hlp)
Microsoft Windows Telephony API (TAPI) Programmer's Reference (tapi.hlp)
Unix Manual Pages

Free Tech Secrets ;) Copyright © 2008 Free Tect Secrets ;) greatis just4fun network just4fun