Diff. B/w Imports & Inherits?
- From: "Arpan" <arpan_de@xxxxxxxxxxx>
- Date: 19 Sep 2006 19:55:17 -0700
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
.
- Follow-Ups:
- Re: Diff. B/w Imports & Inherits?
- From: Sean Chambers
- Re: Diff. B/w Imports & Inherits?
- Prev by Date: Re: looking for a free dual list control
- Next by Date: How do I debug a Class Library?
- Previous by thread: ASP.NET using My.Settings
- Next by thread: Re: Diff. B/w Imports & Inherits?
- Index(es):
Relevant Pages
|