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
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. How to access protected member of CDockBar

How to access protected member of CDockBar

Scheduled Pinned Locked Moved C / C++ / MFC
questiontutorial
8 Posts 2 Posters 0 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
    MaTrIX2k2
    wrote on last edited by
    #1

    I need to get the GetDockedControlBar option of CDockBar, but it says that is a protected member, how can i access to this?

    C 1 Reply Last reply
    0
    • M MaTrIX2k2

      I need to get the GetDockedControlBar option of CDockBar, but it says that is a protected member, how can i access to this?

      C Offline
      C Offline
      Christian Graus
      wrote on last edited by
      #2

      You need CDockBar to be a friend class of yours, or your class needs to be derived from CDockBar. Obviously only the second of those options is possible for you. Christian No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002 Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002

      M 1 Reply Last reply
      0
      • C Christian Graus

        You need CDockBar to be a friend class of yours, or your class needs to be derived from CDockBar. Obviously only the second of those options is possible for you. Christian No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002 Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002

        M Offline
        M Offline
        MaTrIX2k2
        wrote on last edited by
        #3

        I've derived a class from CDockBar, it's called CDockBarEx but i still having the same problem, why is this?

        C 1 Reply Last reply
        0
        • M MaTrIX2k2

          I've derived a class from CDockBar, it's called CDockBarEx but i still having the same problem, why is this?

          C Offline
          C Offline
          Christian Graus
          wrote on last edited by
          #4

          CosmoS2k wrote: why is this? The member is probably private, not protected. a.k.a. you're screwed. Christian No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002 Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002

          M 1 Reply Last reply
          0
          • C Christian Graus

            CosmoS2k wrote: why is this? The member is probably private, not protected. a.k.a. you're screwed. Christian No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002 Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002

            M Offline
            M Offline
            MaTrIX2k2
            wrote on last edited by
            #5

            new error "syntax error : CDockBarEx", now this error appear, i'm confused???

            C 1 Reply Last reply
            0
            • M MaTrIX2k2

              new error "syntax error : CDockBarEx", now this error appear, i'm confused???

              C Offline
              C Offline
              Christian Graus
              wrote on last edited by
              #6

              The code generating this error is clearly not able to see the class. Not that it matters, as I said, if it's private then it's not going to be exposing this variable to you anyhow. Christian No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002 Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002

              M 1 Reply Last reply
              0
              • C Christian Graus

                The code generating this error is clearly not able to see the class. Not that it matters, as I said, if it's private then it's not going to be exposing this variable to you anyhow. Christian No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002 Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002

                M Offline
                M Offline
                MaTrIX2k2
                wrote on last edited by
                #7

                but i can't believe that, the GetDockedControlBar is supposed to be protected member and not private, so how can i acces this?

                C 1 Reply Last reply
                0
                • M MaTrIX2k2

                  but i can't believe that, the GetDockedControlBar is supposed to be protected member and not private, so how can i acces this?

                  C Offline
                  C Offline
                  Christian Graus
                  wrote on last edited by
                  #8

                  If your derived class cannot see it, then it is private, not protected, or it is exposed through some other inheritance mechanism that you've not addressed. look at the source code, it's on your hard drive. Christian No offense, but I don't really want to encourage the creation of another VB developer. - Larry Antram 22 Oct 2002 Hey, at least Logo had, at it's inception, a mechanical turtle. VB has always lacked even that... - Shog9 04-09-2002 Again, you can screw up a C/C++ program just as easily as a VB program. OK, maybe not as easily, but it's certainly doable. - Jamie Nordmeyer - 15-Nov-2002

                  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