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 get Horizontal Scroll on Property Page?

How to get Horizontal Scroll on Property Page?

Scheduled Pinned Locked Moved C / C++ / MFC
c++tutorialquestion
1 Posts 1 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.
  • T Offline
    T Offline
    theFrenchHornet
    wrote on last edited by
    #1

    I have an application that displays dialogs as pages within a property sheet. Most of the controls work fine, but I am having trouble getting an edit box with horizontal scroll to work. I have multiline set to true and horizontal scroll set to true in the properties box for the edit box control. I also have vertical scroll set to true - that works. When the dialog is activated, the horizontal bar does not show up. The vertical bar shows up and works. I have tried to add the horizontal scroll dynamically without success. If I place the code in OnInitDialog for the dialog that has the edit control on it, the program errors out in winocc.cpp in CWnd::ModifyStyle on ASSERT(::IsWindow(m_hWnd) || (m_pCtrlSite !=NULL)): The same happens if I place this call in the OnInitDialog for the main Dialog, after the property page has been added to the property sheet. If I put the call to ModifyStyle in a handler for OnShowWindow, the program does not abort, but the horizontal bar does not show up. Any ideas? Code that sets up the page in the property sheet: dlgPropSheet.AddPage((CPropertyPage*) &msgDlg); dlgPropSheet.Create(this, WS_CHILD | WS_VISIBLE, 0); dlgPropSheet.ModifyStyleEx(0, WS_EX_CONTROLPARENT); dlgPropSheet.ModifyStyle(0, WS_TABSTOP); Code I tried both in OnInitDialog for msgDlg and right after the above code in OnInitDialog for the main dialog: pMsgDlg->m_rawMsg.ModifyStyle(0, WS_HSCROLL);

    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