Hi all,
I want to change the image dynamically in Microsoft Forms 2.0 Image control in dialog box according to the action selected.
Help me,How can i do that...
Expecting the reply....
Thanks and ragards,
sudha_sakthi
Printable View
Hi all,
I want to change the image dynamically in Microsoft Forms 2.0 Image control in dialog box according to the action selected.
Help me,How can i do that...
Expecting the reply....
Thanks and ragards,
sudha_sakthi
Maybe this can lead you in the right direction? Let me know...
http://msdn.microsoft.com/en-us/libr...8VS.60%29.aspx
first of all include
#include <afxctl.h>
now make a variable of image type control by clicking add variable on that control.
Here m_pic is the variable of that control.
CImage img;
img.Load(L"C:\\Users\\Public\\Pictures\\Sample Pictures\\Desert.jpg");
CPictureHolder pictholder;
pictholder.CreateFromBitmap(img.Detach()); // a new bitmap that I created.utref_Picture();
m_pic.putref_Picture(pictholder.GetPictureDispatch());
After that redraw the window.
RedrawWindow();
Now enjoy!