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. Rect Value AGAIN!!!!!!!

Rect Value AGAIN!!!!!!!

Scheduled Pinned Locked Moved C / C++ / MFC
helpc++tutorialquestion
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.
  • L Offline
    L Offline
    Lost User
    wrote on last edited by
    #1

    hi guys i need help on this real bad.... i posted this messege earlier but didnt solve the problem .. will someone plese respond to this .. please........... I have a MFC application dialog based.. has 2 dialog forms say dialog1 and dialog 2.. in dialog1 i have a picture holder (IDC_HOLDER). what i need to do is get the "Rect" value of that holder from dialog2 .. i can do that from dialog1 with CRect rc; GetDlgItem(IDC_HOLDER)->GetWindowRect(rc); but how to access that from dialog2.... i tried CDialog1* dlg; dlg->GetDlgItem(IDC_HOLDER)->GetWindowRect(rc); doesnot work... my whole project has come to HALT by this ... please help .. someone !!!!! thanks zm where are all the GURUS???

    RaviBeeR G 2 Replies Last reply
    0
    • L Lost User

      hi guys i need help on this real bad.... i posted this messege earlier but didnt solve the problem .. will someone plese respond to this .. please........... I have a MFC application dialog based.. has 2 dialog forms say dialog1 and dialog 2.. in dialog1 i have a picture holder (IDC_HOLDER). what i need to do is get the "Rect" value of that holder from dialog2 .. i can do that from dialog1 with CRect rc; GetDlgItem(IDC_HOLDER)->GetWindowRect(rc); but how to access that from dialog2.... i tried CDialog1* dlg; dlg->GetDlgItem(IDC_HOLDER)->GetWindowRect(rc); doesnot work... my whole project has come to HALT by this ... please help .. someone !!!!! thanks zm where are all the GURUS???

      RaviBeeR Offline
      RaviBeeR Offline
      RaviBee
      wrote on last edited by
      #2

      See my answer to this[^] post. /ravi My new year's resolution: 2048 x 1536 Home | Articles | Freeware | Music ravib@ravib.com

      1 Reply Last reply
      0
      • L Lost User

        hi guys i need help on this real bad.... i posted this messege earlier but didnt solve the problem .. will someone plese respond to this .. please........... I have a MFC application dialog based.. has 2 dialog forms say dialog1 and dialog 2.. in dialog1 i have a picture holder (IDC_HOLDER). what i need to do is get the "Rect" value of that holder from dialog2 .. i can do that from dialog1 with CRect rc; GetDlgItem(IDC_HOLDER)->GetWindowRect(rc); but how to access that from dialog2.... i tried CDialog1* dlg; dlg->GetDlgItem(IDC_HOLDER)->GetWindowRect(rc); doesnot work... my whole project has come to HALT by this ... please help .. someone !!!!! thanks zm where are all the GURUS???

        G Offline
        G Offline
        gdocherty
        wrote on last edited by
        #3

        Does dialog1 open dialog2? If it does, try the following: 1. Give dialog2 a member variable - HWND m_hWnd1; 2. Before dialog1 opens dialog2 use - dialog2.m_hWnd1 = m_hWnd; Then use: RECT r; ::GetWindowRect(::GetDlgItem(m_hWnd1, IDC_HOLDER), &r);

        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