Diff. B/w Imports & Inherits?

Tech-Archive recommends: Fix windows errors by optimizing your registry



What's the difference between "Imports" & "Inherits"? For e.g. both the
codes below work without any errors:

Imports System
Imports System.Data
Imports System.Web.UI

Namespace Constructors
Public Class Constr : Inherits Page
Public Sub New()
Response.Write("Constructor1")
End Sub
End Class
End Namespace

----------

Imports System
Imports System.Data

Namespace Constructors
Public Class Constr : Inherits System.Web.UI.Page
Public Sub New()
Response.Write("Constructor1")
End Sub
End Class
End Namespace

In the first code snippet, I am importing "System.Web.UI" & then
inheriting the "Page" class where as in the second code snippet, I am
just inheriting "System.Web.UI.Page". So what's the difference between
importing & inheriting?

Thanks,

Arpan

.



Relevant Pages

  • Re: DLL permission check in vba
    ... Imports System.Security ... Public Sub GetFileCreationTime ... 'Initialize DirectoryInfo object to the passed directory. ... Dim DirFiles As New DirectoryInfo ...
    (microsoft.public.office.developer.vba)
  • Help: .net soap client sees empty responses from Axis
    ... messages my client sends are processed fine by the server, ... Imports System.ComponentModel ... Public Function echoAs ... Public Sub setEchoMode ...
    (microsoft.public.dotnet.framework.webservices)
  • Re: Button1.PerformClick() problem
    ... You can't have html tags in your code-behind or other class files. ... remove all the code before your "Imports" calls, ... > Public Property DialogResult() As DialogResult Implements ... > Public Sub NotifyDefaultImplements ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Dim oRpt As New CrystalReport1() failing
    ... the public sub reportprod doesn't seem to be doing much when I test. ... So, now, I want my "vendor" parameter to call the report with discrete values and not show the crystal report default parameter dialog box. ... Imports System.Data.OleDb ... Dim pdvProdId As New CrystalDecisions.Shared.ParameterDiscreteValue ...
    (microsoft.public.dotnet.languages.vb)
  • Re: How to use Windows Authentication
    ... Imports System.Security ... Public Class WindowsIdentityCheck ... Public Sub ValidateUserAccount(ByVal userName As String, ...
    (microsoft.public.dotnet.framework)