Re: CClientDC and TabCtrl ?

Tech-Archive recommends: Fix windows errors by optimizing your registry



I think it is better to have a CWnd derived control (custom control) and
have the control handle the drawing. The tab control should then use the
Custom control.

--
Vipin Aravind
http://www.explorewindows.com


"Joseph M. Newcomer" <newcomer@xxxxxxxxxxxx> wrote in message
news:rr7oc25cfu3lm0nnpvucc4ck913va9p9kf@xxxxxxxxxx
No. What you do is create a class which has this responsibility, and make
all your other
pages subclasses of this class (see my essay on subclassing dialogs and
property pages on
my MVP TIps site). What I would do is simply provide the bitmap ID as a
property of the
superclass, but each subclass sets it uniquely, then the OnPaint handler
would only
retrieve this using a virtual method and draw whatever bitmap the virtual
method returned.
Or I'd use the ability to use the image list instead.
joe

On Sat, 29 Jul 2006 21:01:23 GMT, "cdg" <anyone@xxxxxxxxxxxx> wrote:


"Scott McPhillips [MVP]" <org-dot-mvps-at-scottmcp> wrote in message >

The painting must be done in the WM_PAINT message handler OnPaint.


So, it's necessary to create a WM_PAINT message handler for each Tab
Page
Form that requires any painting. But how is it called. I tried
UpdateWindow() and it didn't work.
The way that I've written this program, there is a function call (with
arguments) to a member function of this Tab Page Form Class. And then
after
some processsing in this function, I just used the code that I previouly
posted to paint the bitmaps on the Tab Form.
Could you explain how I should correctly write this.


Joseph M. Newcomer [MVP]
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm


.



Relevant Pages

  • Re: Asp.Net AJAX dynamically added Tab Control not displaying
    ... TabPanel assumes there's no active tab and it hides all the tabs at client ... protected void Page_PreRender ... Microsoft is providing this information as a convenience to you. ... does not control these sites and has not tested any software or information ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Subform trouble for New User
    ... control as suggested. ... I didn't use that field in the Subform Field Linker). ... The structure of this tab is ... continuous form.I have limited the fields in the continuous form to ...
    (microsoft.public.access.forms)
  • Re: Tab Control
    ... here's the code on an Option Group control that changes ... to the corresponding index value of the tab control page you ... click to go to the first tab page, and set the button's OptionValue property ... i keep the list of available subforms in tbl00SubformReports, ...
    (microsoft.public.access.formscoding)
  • Re: Calculated fields in subforms of Tab Control not refreshing
    ... Private Sub TabCtl0_Change ... from the drop down so that the tab selection works on first click. ... Right-click the edge of a subform control, ... Calculations in some fields use data from fields in other ...
    (microsoft.public.access.modulesdaovba)
  • RE: cant seem to control tab order
    ... Thanks for the added info. I've learned quite a few details about the tab ... control in the last few days. ... it's own tab order, and then each page on the tab control has it's own order. ... tab order of a control "within" a rectangle, ...
    (microsoft.public.access.forms)