PRB: Using Animation Resources with the Animation Control
Article ID: 149688
Article Last Modified on 7/11/2005
APPLIES TO
- Microsoft Platform Software Development Kit-January 2000 Edition
This article was previously published under Q149688
SYMPTOMS
When sending the ACM_OPEN message to an animation control, you have the
option of using an ANI file or an ANI resource. When you specify a
resource, you cannot specify which module to load that resource from.
CAUSE
When loading an animation resource, the control uses the hInstance that it
was created with (the hInstance passed to CreateWindow, DialogBox, or
CreateDialog).
RESOLUTION
Use an animation file or store the animation resource in the same module
from which the animation control was created. One other alternative, which
is probably not a good idea, is to retrieve the resource by using
FindResource, LoadResource, and LockResource, and then save that to a
temporary animation file. The drawback to this method is that you need to
make sure that the temporary file is deleted.
STATUS
This behavior is by design.
Keywords: kbanimation kbprb kbctrl KB149688