Click here to Skip to main content
15,894,343 members

Comments by Member 11380615 (Top 22 by date)

Member 11380615 26-Apr-18 9:53am View    
Each individual view the scroll sizes have been set.
Member 11380615 26-Apr-18 9:53am View    
I tried adding the OnVScroll to the ScrollView class. SetScrollSizes were also called in the view class. There was only one scroll bar and that was in the main frame window. Despite me being able to scroll up and down through the mdi client area the call back function OnVScroll never got called.
Member 11380615 25-Apr-18 22:10pm View    
Thanks Jochen. I do find that the MDI frame window automatically creates a vertical and horizontal scroll bar when the child windows go beyond the extent of the mdi client area. The MDI frame window scroll bar works fine when it is there. Scrolling works fine.
My objectve is to trap the scrolling event when ever the user tries to scroll. Would it be possible to trap the MDI frame window scrolling in the active view class using WM_HSCROLL, WM_VSCROLL. If so how would we differentiate between the scrolling of the view window and the MDI main frame window.
Member 11380615 25-Apr-18 22:02pm View    
Thanks Richard, Yes a scroll bar appears on the main frame window. Whenever the number of child windows and their end to end extent go beyond the MDI client area and vertical and horizontal scroll bar automatically appears.
I was not able to call SetScrollSizes since the function is not available in the main frame class.
Member 11380615 1-May-17 23:57pm View    
ID_FILE_NEW is mapped to OnFileNew1 . Which is what the system calls when creating the first mdi child window. When user creates new mdi child windows OnFileNew is used. Both OnFileNew and OnFIleNew1 are functions in theApp.

void CMarkBullNewVApp::OnFileNew1()
{
tagPlot ltempPlot;
theApp.Is_Graph_Data_3D = ANIMATION_WIN;
ltempPlot.WinCount = 0;
ltempPlot.Is_Graph_Data_3D = ANIMATION_WIN;
ltempPlot.Graph_Type = 0;// ii++;
ltempPlot.WinViewMap = 1;// lnumPlotCount[ii];
ltempPlot.RowCol[0] = 0;// DataColumnInt[jj];
strncpy(ltempPlot.PlotLegend[0], "0", 200);
ltempPlot.m_szXCaption[0] = "0";// m_szXCaption[0];
ltempPlot.m_szYCaption[0] = "0";// m_szYCaption[0];
ltempPlot.DirectionPlus[0] = "0";// DirectionPlus[0];
ltempPlot.DirectionMinus[0] = "0";// DirectionMinus[0];
theApp.plotList.clear();
theApp.plotList.push_back(ltempPlot);
CWinAppEx::OnFileNew(); // call base class method and / or...
// ...add other tasks here.
}


void CMarkBullNewVApp::OnFileNew()
{
CWinAppEx::OnFileNew(); // call base class method and / or...
}