Hello,
I used the Doc/View architecture to create a split screen application. On startup, the screen is already split horizontally. I did the following in the MainFrm class: - BOOL CMainFrame::OnCreateClient(LPCREATESTRUCT /*lpcs*/,
-
CCreateContext* pContext)
-
{
-
if(m_wndSplitter.Create(this,
-
2, 2, // TODO: adjust the number of rows, columns
-
CSize(10, 10), // TODO: adjust the minimum pane size
-
pContext))
-
{
-
PostMessage(WM_APP + 1);
-
return TRUE;
-
}
-
else
-
return FALSE;
-
}
- BEGIN_MESSAGE_MAP(CMainFrame, CFrameWnd)
-
ON_WM_CREATE()
-
ON_MESSAGE(WM_APP + 1,OnApp1)
-
END_MESSAGE_MAP()
-
-
LRESULT CMainFrame::OnApp1(WPARAM, LPARAM)
-
{
-
m_wndSplitter.SplitRow(100);
-
return 0;
-
}
My question is how can i access the different parts of the screen? For example, if I want to put something in the top portion, how would I do that? What is the top portion defined as?
This is the first time I use Doc/View, so I'm not familiar with the higher level stuff.
Thanks
2 2854 Banfa 9,065
Expert Mod 8TB
You will need to create view windows for the 2 halfs of the splitter window which will need to have been derived from CView (although not necessarily directly).
Then call the method m_wndSplitter.CreateView(...)
Then you can call m_wndSplitter.GetPane(...) to get pointers to the classes of the view windows for the 2 halfs of the splitter window.
How do you do that?
I tried this: - m_wndSplitter.CreateView(0, 0, RUNTIME_CLASS(CSplitMFCView), CSize(10, 10), pContext);
But it didn't work. CSplitMFCView is my own class that inherits from CView. The file SplitMFCView.h is included in my MainFrm.cpp file.
The error is: - error C2653: 'CSplitMFCView' : is not a class or namespace name
What am I missing here?
Thanks
Sign in to post your reply or Sign up for a free account.
Similar topics
by: news.microsoft.com |
last post by:
This is a cross post....
My problem is when I am using the split screen editor and I copy and paste
from the bottom pane to the top pane, the top pane will reposition itself to
where the bottom...
|
by: Neil |
last post by:
I previously posted re. this, but thought I'd try again with a summary of
facts.
I have an Access 2000 MDB with a SQL Server 7 back end. There is a view that
is linked to the database via ODBC...
|
by: Maryam |
last post by:
Is a split window possible for an MS DOS program and MS Access program?? If
so how???
When you run a DOS programn it covers the whole of the PC screen and if you
have other applications you...
|
by: Brian Henry |
last post by:
Here is another virtual mode example for the .NET 2.0 framework while
working with the list view. Since you can not access the items collection of
the list view you need to do sorting another...
|
by: wiewel |
last post by:
hi all,
i have a strange problem when trying to set up a horizontal menubar:
i would like to split the whole screen from left to right into 9
pieces. the first one has a fixed width of 186px....
|
by: James L |
last post by:
I have a tree view with a root, 3 noodes(1,2,3) each having one sub node.
I drill down to a node.
I get the path by saying treeView1.selectedNode.fullpath and assign it to a
variable.
If I...
|
by: Bill Nguyen |
last post by:
I'm working on a project that requires outputs to be sent to multiple
windows on a single monitor.
I have no idea whether .NET can provide this capability. Also, is there any
utility/control out...
|
by: cjl |
last post by:
Hi.
I am trying to screen scrape some stock data from yahoo, so I am
trying to use urllib2 to retrieve the html and beautiful soup for the
parsing.
Maybe (most likely) I am doing something...
|
by: Mike TI |
last post by:
Nov 13, 2007
Hi all
I have an application that comprises of three modules.
Initially a screen is displayed. Upon selection from a menu on this screen,
module 1, module 2 or module 3 is...
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
| |