Solved

Create View from another View

Posted on 1997-10-17
2
460 Views
Last Modified: 2013-11-20
I'm in that situation. I've created a View, I've two button controls. If I say 'ok' I want to create another View, if I say 'cancel' I want to create another View, not always the previous one. I've thinked to get the mainframe pointer and switch from views using it, but I've not found the command to get it. The best is to create view directly from the other view. Can I have the simplest way to do that ?
0
Comment
Question by:css
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 3

Expert Comment

by:shaig
ID: 1308264
If it is nessasery to keep the original view alive after pressing buttons then:
create all needed view's befor and switch between them trough
CFrameWnd::SetActiveView    //your mainframe class is derived from CFrameWnd

If it isn't nessasery to keep the original view exsisting, then simply destroy it and create a new one.
0
 
LVL 1

Accepted Solution

by:
IgorGrebnev earned 10 total points
ID: 1308265
You can get pointer to mainframe with
"GetParentFrame" funciton
0

Featured Post

[Webinar] Learn How Hackers Steal Your Credentials

Do You Know How Hackers Steal Your Credentials? Join us and Skyport Systems to learn how hackers steal your credentials and why Active Directory must be secure to stop them. Thursday, July 13, 2017 10:00 A.M. PDT

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction: The undo support, implementing a stack. Continuing from the eigth article about sudoku.   We need a mechanism to keep track of the digits entered so as to implement an undo mechanism.  This should be a ‘Last In First Out’ collec…
If you use Adobe Reader X it is possible you can't open OLE PDF documents in the standard. The reason is the 'save box mode' in adobe reader X. Many people think the protected Mode of adobe reader x is only to stop the write access. But this fe…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Monitoring a network: why having a policy is the best policy? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the enormous benefits of having a policy-based approach when monitoring medium and large networks. Software utilized in this v…

623 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question