Print Page | Close Window

Adding an icon to the property sheet header

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Property Grid
Forum Description: Topics Related to Codejock Property Grid
URL: http://forum.codejock.com/forum_posts.asp?TID=22364
Printed Date: 23 November 2024 at 7:20am
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: Adding an icon to the property sheet header
Posted By: sivavuyyuru
Subject: Adding an icon to the property sheet header
Date Posted: 17 July 2014 at 5:22am
Hi,

I had a property sheet (Wizard style(PSH_WIZARD97),as we know that a property sheet of that style consists of header. Exactly here arises my problem.The problem is I got a situation to add a bitmap to the property sheet header and again on that bitmap i must be able to place two icons at two top corners i.e,one icon at left top corner and another at right top corner and a static text control in between them .I hope you might have got what I am trying to say .

1)Creating a property sheet with PSH_WIZARD97 style .-----Done.
2)Adding bitmap to the header of property sheet.-------------Done.
3)Placing two icons at two top corners on the bitmap and those icons should be transparent as mentioned above .-----Need Help.
4)Placing a static text control in between the two icons on the property sheet header and this also should be transparent-----Need Help.

For setting the property sheet header title I added this piece of code in the page's constructor's to set the title on the sheet header,

m_psp.dwFlag |= PSP_DEFAULT|PSP_USEHEADERTITLE;
m_psp.pszHeaderTitle = L"My Application";

Adding this snippet in all the page classes make the header title to appear on all the pages,but here the text which is being set on the header is not transparent and looks ugly .So,I tried implementing WM_CTLCOLOR where I added this piece of code.

pDC->SetBkMode(TRANSPARENT);

But still the text is not transparent and this text is set on the sheet header at left top corner ,but I must place the icon and the text should follow that icon ,but if add as i mentioned above it just overlaps with the icon.


If you want source code for this ,please let me know how to send.

Any suggestions is appreciated.Smile


Thanks in advance..Smile


-------------
SivaVuyyuru



Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net