Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. ATL / WTL / STL
  4. subclassing without resource

subclassing without resource

Scheduled Pinned Locked Moved ATL / WTL / STL
questionlearning
5 Posts 3 Posters 1 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    merlinos
    wrote on last edited by
    #1

    Hi, I need to customize the CEdit control to use character masks. I thought of subclassing but the CEdit controls I need to customize are on a view that is created from scratch, so there is no CEdit resource to attach to with a GetDlgItem. The existing CEdit controls are created with a call to Create(). How can I subclass without a resource? Thanks, Merlinos

    P J 2 Replies Last reply
    0
    • M merlinos

      Hi, I need to customize the CEdit control to use character masks. I thought of subclassing but the CEdit controls I need to customize are on a view that is created from scratch, so there is no CEdit resource to attach to with a GetDlgItem. The existing CEdit controls are created with a call to Create(). How can I subclass without a resource? Thanks, Merlinos

      P Offline
      P Offline
      prasad_som
      wrote on last edited by
      #2

      merlinos wrote:

      How can I subclass without a resource?

      Use CWnd::SubclassWindow. BTW, this question is appropriate for VC++ forum.

      Prasad Notifier using ATL | Operator new[],delete[][^]

      J 1 Reply Last reply
      0
      • P prasad_som

        merlinos wrote:

        How can I subclass without a resource?

        Use CWnd::SubclassWindow. BTW, this question is appropriate for VC++ forum.

        Prasad Notifier using ATL | Operator new[],delete[][^]

        J Offline
        J Offline
        Jorgen Sigvardsson
        wrote on last edited by
        #3

        He's probably using WTL, otherwise he wouldn't have bothered asking the question in this forum, nor would he even ask this very question, as subclassing is automatic in MFC. Hence, his question is very much appropriate for this forum.

        -- Verletzen zerfetzen zersetzen zerstören Doch es darf nicht mir gehören Ich muss zerstören

        P 1 Reply Last reply
        0
        • M merlinos

          Hi, I need to customize the CEdit control to use character masks. I thought of subclassing but the CEdit controls I need to customize are on a view that is created from scratch, so there is no CEdit resource to attach to with a GetDlgItem. The existing CEdit controls are created with a call to Create(). How can I subclass without a resource? Thanks, Merlinos

          J Offline
          J Offline
          Jorgen Sigvardsson
          wrote on last edited by
          #4

          See: CWindow::SubclassWindow()

          -- Verletzen zerfetzen zersetzen zerstören Doch es darf nicht mir gehören Ich muss zerstören

          1 Reply Last reply
          0
          • J Jorgen Sigvardsson

            He's probably using WTL, otherwise he wouldn't have bothered asking the question in this forum, nor would he even ask this very question, as subclassing is automatic in MFC. Hence, his question is very much appropriate for this forum.

            -- Verletzen zerfetzen zersetzen zerstören Doch es darf nicht mir gehören Ich muss zerstören

            P Offline
            P Offline
            prasad_som
            wrote on last edited by
            #5

            Joergen Sigvardsson wrote:

            He's probably using WTL

            Probably ! Seeing mention of CEdit leads my assumption.

            Prasad Notifier using ATL | Operator new[],delete[][^]

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups