Just so you know, what you have as [ProjectName] is actually the Project's Namespace. By default the namespace for the project is the same name as the project; however this can be changed, so the ProjectName does not always match the Project's Namespace.
Anyways, your @Page directive should look something like:
-
<%@ Page MasterPageFile="[relative path to the master page]"
-
CodeBehind="registerbusiness.aspx.vb"
-
Inherits="[ProjectNamespace].registerbusiness"
-
Language="vb"
-
%>
When you look at code implementation found in your registerbusiness.aspx.vb you should see the a Partial Class with the same name as specified in your @Page directive's Inherit attribute. If this name is different then it won't work. If the partial class is in a different namespace, then it won't work either.
Here's an example of the @Page directive for a page that uses a MasterPage (located in the root of the project) from my project:
-
<%@ Page MasterPageFile="~/MasterPage.master"
-
CodeBehind="Default.aspx.vb"
-
Inherits="TestProject.Default"
-
Language="vb"
-
%>
And the VB.NET code in the Default.aspx.vb file looks like:
-
Partial Public Class Default
-
Inherits System.Web.UI.Page
-
'......
-
'......
-
End Class
The default namespace (for the project) is automatically applied to the Default partial class.
-Frinny