I’ve just create a new MVC project, and have made no changes at all, but when I try and view the ChangePasswordSuccess view in design mode, I get the error:
The page has controls that require a Master Page reference, but none is supplied.
The page has no controls except for a content control and literal text, and it does have a master page reference. Anyone know what’s up?
<%@Language='C#' MasterPageFile='~/Views/Shared/Site.Master' AutoEventWireup='true' CodeBehind='ChangePasswordSuccess.aspx.cs' Inherits='BasicMvcApp.Views.Account.ChangePasswordSuccess' %> <asp:Content ID='changePasswordSuccessContent' ContentPlaceHolderID='MainContent' runat='server'> <h2>Change Password</h2> <p> Your password has been changed successfully. </p> </asp:Content>
No sooner asked than noticed. The default ChangePasswordSuccess view’s Page directive is missing the word
Page.