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. C / C++ / MFC
  4. Resize a dialog

Resize a dialog

Scheduled Pinned Locked Moved C / C++ / MFC
question
3 Posts 3 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.
  • J Offline
    J Offline
    john5632
    wrote on last edited by
    #1

    One parent dialog is containing 2 child dialog but one at a time. I need to resize one and not to resize other. How can I do?

    CPalliniC M 2 Replies Last reply
    0
    • J john5632

      One parent dialog is containing 2 child dialog but one at a time. I need to resize one and not to resize other. How can I do?

      CPalliniC Offline
      CPalliniC Offline
      CPallini
      wrote on last edited by
      #2

      What's wrong in calling SetWindowPos[^] just for the right child?

      Veni, vidi, vici.

      In testa che avete, signor di Ceprano?

      1 Reply Last reply
      0
      • J john5632

        One parent dialog is containing 2 child dialog but one at a time. I need to resize one and not to resize other. How can I do?

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

        You need to do it manually. Get the parent dialog client size (CWnd::GetClientRect) and use either CWnd::MoveWindow or CWnd::SetWindowPos to move/resize the child dialog of your choice. be careful about the CRect that is returned by GetClientRect, you might have to use ScreenToClient to ClientToScreen to convert the rect before move/resize the child dialogs.

        I'd rather be phishing!

        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