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
Solved

Launch page from another page

Posted on 2007-12-03
8
141 Views
Last Modified: 2010-04-06
I created a Master page with two content holder.
One will be used for the tree view. Another for the different pages.
When i link to the second page, how could i load the first content page? What is the syntex?
0
Comment
Question by:iyufa
  • 3
  • 3
8 Comments
 
LVL 29

Expert Comment

by:Göran Andersson
ID: 20397366
A master page doesn't work that way. Each content page contains all the contents for the content holders in the master page.

If you want the tree view in all pages, put it in the master page, or put it in a user control that you can reuse in several content pages.
0
 

Author Comment

by:iyufa
ID: 20397881
i got this request from my Busness  Analyst. So you are saying that I cann't do that?
0
 
LVL 29

Expert Comment

by:Göran Andersson
ID: 20398192
Exactly. You can't do that. The request is based on a false assumption.

If the master page would be the base, and the content page was included in the master page, you could do that, but that is not the case. The content page is the base, and the master page is is included as a template for the content page. A master page can actually itself have another master page as template.
0
Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

 

Author Comment

by:iyufa
ID: 20398300
Let's start over.
I created A Master page one with one Content Page (contain the list of the menu and details)
Also I created a Master Page2 with two Content Pages.
Content holder1  will be a place for the different pages. ex. GMM.aspx
Content Holder2 will be a place for the tree view ex TreeView.aspx
My default page will be a Master page one. Then when i click on one of the menu selection it should load a page GMM.aspx And inside of this page i want to do a          Response.Redirect("\TreeView.aspx")
Can i do that?
As a result I am expecting  both of my  pages (from both content pages to be load)
Can i do that?



0
 
LVL 29

Accepted Solution

by:
Göran Andersson earned 500 total points
ID: 20398500
No, you can't do that. You can't have two content pages in a master page.

You never browse to the master page. You always browse to the content page. The content page loads the master page as a template, and the content place holders in the master page is filled by the content elements from the content page. All content elements used in a master page comes from the same content page.

If you do a redirect, the current response is scrapped, and instead a redirection page is sent to the browser. The browser then sends a new request for the page that you specified in the redirect.

It's possible to use Server.Transfer to execute one page from another, but that is a complicated way of doing it, that requires you to output partial documents from the pages.

Just put the tree view in a user control, so that you can use it anywhere you like.
0
 

Author Comment

by:iyufa
ID: 20398525
Thank you
0
 
LVL 1

Expert Comment

by:Computer101
ID: 20561754
Forced accept.

Computer101
EE Admin
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

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

If you need to start windows update installation remotely or as a scheduled task you will find this very helpful.
These days, all we hear about hacktivists took down so and so websites and retrieved thousands of user’s data. One of the techniques to get unauthorized access to database is by performing SQL injection. This article is quite lengthy which gives bas…
This video teaches users how to migrate an existing Wordpress website to a new domain.
Use Wufoo, an online form creation tool, to make powerful forms. Learn how to choose which pages of your form are visible to your users based on their inputs. The page rules feature provides you with an opportunity to create if:then statements for y…

856 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