System.Web.UI.Page.ApplyMasterPage C# (CSharp) Method

ApplyMasterPage() private method

private ApplyMasterPage ( ) : void
return void
	void ApplyMasterPage ()
	{
		if (masterPageFile != null && masterPageFile.Length > 0) {
			MasterPage master = Master;
			
			if (master != null) {
				var appliedMasterPageFiles = new Dictionary <string, bool> (StringComparer.Ordinal);
				MasterPage.ApplyMasterPageRecursive (Request.CurrentExecutionFilePath, HostingEnvironment.VirtualPathProvider, master, appliedMasterPageFiles);
				master.Page = this;
				Controls.Clear ();
				Controls.Add (master);
			}
		}
	}
Page