C# 2010 linkage through master pages
-
I have a question about understanding how the master pages in C# 2010 web application are linked (wired together). I am asking that question since I believe I and/or my co-worker placed some test code in the location where the production code was actually stored. What is happening is when I try to debug the production application using iis 7, a reference to a master page and/or an *ascx file is lost. The file that it is trying to access, is for a test version of one of the production modules. This test version of the production code is mainly commented out in the code right now. The part of the test code that actually is running is the startup file name that looks like 'startup2.aspx'. The test code is actually calling 'startup2.aspx' instead of 'startup.aspx'. Thus to understand how the master pages are wired together I am thinking that I will debug the application from the time any code starts running. Can you tell me if this is a good idea? Also I am wondering if you can tell me how master pages are actually 'wired' together? is there a good reference that I can look at?
-
I have a question about understanding how the master pages in C# 2010 web application are linked (wired together). I am asking that question since I believe I and/or my co-worker placed some test code in the location where the production code was actually stored. What is happening is when I try to debug the production application using iis 7, a reference to a master page and/or an *ascx file is lost. The file that it is trying to access, is for a test version of one of the production modules. This test version of the production code is mainly commented out in the code right now. The part of the test code that actually is running is the startup file name that looks like 'startup2.aspx'. The test code is actually calling 'startup2.aspx' instead of 'startup.aspx'. Thus to understand how the master pages are wired together I am thinking that I will debug the application from the time any code starts running. Can you tell me if this is a good idea? Also I am wondering if you can tell me how master pages are actually 'wired' together? is there a good reference that I can look at?
dcof wrote:
I am thinking that I will debug the application from the time any code starts running. Can you tell me if this is a good idea?
Yes, that should help. Do, make sur before making this effort, you clear your temporary files, cache, reset IIS and then recheck things on how they are working (just to avoid these be the reason of old file refrence issue.) BTW, I hope if there was a new deployment then, it's not just a file.
dcof wrote:
is there a good reference that I can look at?
Look here: MSDN: ASP.NET Master Pages[^] ASPNET: ASP.NET Master Pages Tutorials[^] ASP.NET 2.0 Master Pages[^]
Sandeep Mewara [My last article]: Server side Delimiters in ASP.NET[^]
-
dcof wrote:
I am thinking that I will debug the application from the time any code starts running. Can you tell me if this is a good idea?
Yes, that should help. Do, make sur before making this effort, you clear your temporary files, cache, reset IIS and then recheck things on how they are working (just to avoid these be the reason of old file refrence issue.) BTW, I hope if there was a new deployment then, it's not just a file.
dcof wrote:
is there a good reference that I can look at?
Look here: MSDN: ASP.NET Master Pages[^] ASPNET: ASP.NET Master Pages Tutorials[^] ASP.NET 2.0 Master Pages[^]
Sandeep Mewara [My last article]: Server side Delimiters in ASP.NET[^]
When you mention "clear your temporary files, cache, reset IIS", I think you mean I should stop and start my workstation and stop and start iis that is on my work station correct? If this is not what you mean, can you tell me what you mean? You mentioned, "I hope if there was a new deployment then, it's not just a file." There was no new deployment. Thus what would I be concerened about with a file? Thanks for the online references!
-
I have a question about understanding how the master pages in C# 2010 web application are linked (wired together). I am asking that question since I believe I and/or my co-worker placed some test code in the location where the production code was actually stored. What is happening is when I try to debug the production application using iis 7, a reference to a master page and/or an *ascx file is lost. The file that it is trying to access, is for a test version of one of the production modules. This test version of the production code is mainly commented out in the code right now. The part of the test code that actually is running is the startup file name that looks like 'startup2.aspx'. The test code is actually calling 'startup2.aspx' instead of 'startup.aspx'. Thus to understand how the master pages are wired together I am thinking that I will debug the application from the time any code starts running. Can you tell me if this is a good idea? Also I am wondering if you can tell me how master pages are actually 'wired' together? is there a good reference that I can look at?
Hey, Just something to note, everybody is lead to believe that content pages are placed in to master pages when the application runs but it's actually the other way round, when you run you application, the webpage you run actually pulls the master page an displays it. So in short the content page is fired first and then the master page. Hope this helps you understand.
-
When you mention "clear your temporary files, cache, reset IIS", I think you mean I should stop and start my workstation and stop and start iis that is on my work station correct? If this is not what you mean, can you tell me what you mean? You mentioned, "I hope if there was a new deployment then, it's not just a file." There was no new deployment. Thus what would I be concerened about with a file? Thanks for the online references!
dcof wrote:
"clear your temporary files, cache, reset IIS", I think you mean I should stop and start my workstation and stop and start iis that is on my work station correct?
No, not just that, you need to also clear your browsers cache and system temporary files.
dcof wrote:
I hope if there was a new deployment then, it's not just a file." There was no new deployment. Thus what would I be concerened about with a file
If you are replacing/updating a file then you need to make sure it's nothing more than a ASPX file with all it's class references intact. If you make any change in code behind file then you need to rebuild before deployment.
Sandeep Mewara [My last article]: Server side Delimiters in ASP.NET[^]