المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : image in picture control not displayed properly after moving



C++ Programming
05-30-2009, 12:12 AM
Hello, I'm writing a MFC application to move a picture control when i press the "Next" button. (Please see screen-captures at following links)
http://i238.photobucket.com/albums/ff191/pumbaboy/before-move.jpg[^ (http://i238.photobucket.com/albums/ff191/pumbaboy/before-move.jpg)]
http://i238.photobucket.com/albums/ff191/pumbaboy/after-move.jpg[^ (http://i238.photobucket.com/albums/ff191/pumbaboy/after-move.jpg)]

There is a dialog box on which there are 2 picture controls. When I press the Next button, the left picture control should move on top of the right picture control.
You can see I kept the code for moving the picture control in a for loop because I wanted a sort of animation effect.

As you can see from the attachments, after I move the image there are some vertical lines appearing. How do I make them go away?


Thank you.

void CShabbirDlg::OnBnClickedButton2()
{
// TODO: Add your control notification handler code here
if (pageNum RRect.left; i -= 20) {
picPreview.MoveWindow(i , LRect.top, LRect.Width(), LRect.Height());
}
}


}