MFC Dialogue based application

58 Views Asked by At

Good day, I am trying to add a bitmap image to my dialogue-based application using MFC ( VSTUDIO 2019 ). I wish to position my image at the center of the application. How do I get the size of the current rectangle so that it can be given as an input to BitBlt() function? Thanks in advance

1

There are 1 best solutions below

2
Andrew Truckle On

As mentioned in the comments, you can use GetClientRect to get the dimensions use refer to. My answer here provides some additonal information about GetClientRect and the other variants.