Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > Having problems with namespaces

Reply
Thread Tools

Having problems with namespaces

 
 
clintonG
Guest
Posts: n/a
 
      04-02-2008
namespace CompanyName
{
public partial class ...
{
...
}
}

Keeps failing when trying to use a namespace on a new web site. I've tried
with page classes that inherit from System.Web.UI.Page, my own
CommonBaseClass : System.Web.UI.Page, pages that inherit the CommonBaseClass
and when using a MasterPage. I just keep getting the same error...

// no idea what this implies...
Compiler Error Message:
CS0115: 'ASP.default_aspx.GetTypeHashCode()':
no suitable method found to override

 
Reply With Quote
 
 
 
 
Cowboy \(Gregory A. Beamer\)
Guest
Posts: n/a
 
      04-02-2008
Not looking up anything, but I would find GetTypeHashCode and find out why
it is not overriding. I would also clear out any temporary ASP.NET files, as
that causes issues from time to time. Once cleared, it uis usually fine.

Here is my problem with Temporary ASP.NET files:
http://gregorybeamer.spaces.live.com/blog/cns!B036196EAF9B34A8!510.entry

--
Gregory A. Beamer
MVP, MCP: +I, SE, SD, DBA

Subscribe to my blog
http://gregorybeamer.spaces.live.com/lists/feed.rss

or just read it:
http://gregorybeamer.spaces.live.com/

*************************************************
| Think outside the box!
|
*************************************************
"clintonG" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> namespace CompanyName
> {
> public partial class ...
> {
> ...
> }
> }
>
> Keeps failing when trying to use a namespace on a new web site. I've tried
> with page classes that inherit from System.Web.UI.Page, my own
> CommonBaseClass : System.Web.UI.Page, pages that inherit the
> CommonBaseClass and when using a MasterPage. I just keep getting the same
> error...
>
> // no idea what this implies...
> Compiler Error Message:
> CS0115: 'ASP.default_aspx.GetTypeHashCode()':
> no suitable method found to override



 
Reply With Quote
 
 
 
 
George Ter-Saakov
Guest
Posts: n/a
 
      04-02-2008
Post here your <%@Page directive

I think you inheriting there from class that does not exist...

Must be something like
Inherits="CompanyName._Defaul"

George.



"clintonG" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> namespace CompanyName
> {
> public partial class ...
> {
> ...
> }
> }
>
> Keeps failing when trying to use a namespace on a new web site. I've tried
> with page classes that inherit from System.Web.UI.Page, my own
> CommonBaseClass : System.Web.UI.Page, pages that inherit the
> CommonBaseClass and when using a MasterPage. I just keep getting the same
> error...
>
> // no idea what this implies...
> Compiler Error Message:
> CS0115: 'ASP.default_aspx.GetTypeHashCode()':
> no suitable method found to override



 
Reply With Quote
 
Juan T. Llibre
Guest
Posts: n/a
 
      04-02-2008
re:
I would find GetTypeHashCode and find out why it is not overriding

It's a page compiler method :

private void BuildGetTypeHashCodeMethod();
Declaring Type: System.Web.Compilation.PageCompiler

private void BuildGetTypeHashCodeMethod()
{
CodeMemberMethod method = new CodeMemberMethod();
method.Name = "GetTypeHashCode";
method.ReturnType = new CodeTypeReference(typeof(int));
method.Attributes &= ~MemberAttributes.AccessMask;
method.Attributes &= ~MemberAttributes.ScopeMask;
method.Attributes |= MemberAttributes.Public | MemberAttributes.Override;
base._sourceDataClass.Members.Add(method);
method.Statements.Add(new CodeMethodReturnStatement(new CodePrimitiveExpression(this.Parser.TypeHashCode)) );
}




Juan T. Llibre, asp.net MVP
asp.net faq : http://asp.net.do/faq/
foros de asp.net, en espaņol : http://asp.net.do/foros/
======================================
"Cowboy (Gregory A. Beamer)" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Not looking up anything, but I would find GetTypeHashCode and find out why it is not overriding. I would also clear
> out any temporary ASP.NET files, as that causes issues from time to time. Once cleared, it uis usually fine.
>
> Here is my problem with Temporary ASP.NET files:
> http://gregorybeamer.spaces.live.com/blog/cns!B036196EAF9B34A8!510.entry
>
> --
> Gregory A. Beamer
> MVP, MCP: +I, SE, SD, DBA
>
> Subscribe to my blog
> http://gregorybeamer.spaces.live.com/lists/feed.rss
>
> or just read it:
> http://gregorybeamer.spaces.live.com/
>
> *************************************************
> | Think outside the box! |
> *************************************************
> "clintonG" <(E-Mail Removed)> wrote in message news:%(E-Mail Removed)...
>> namespace CompanyName
>> {
>> public partial class ...
>> {
>> ...
>> }
>> }
>>
>> Keeps failing when trying to use a namespace on a new web site. I've tried with page classes that inherit from
>> System.Web.UI.Page, my own CommonBaseClass : System.Web.UI.Page, pages that inherit the CommonBaseClass and when
>> using a MasterPage. I just keep getting the same error...
>>
>> // no idea what this implies...
>> Compiler Error Message:
>> CS0115: 'ASP.default_aspx.GetTypeHashCode()':
>> no suitable method found to override

>
>




 
Reply With Quote
 
clintonG
Guest
Posts: n/a
 
      04-02-2008
GetTypeHashCode Documentation says this:
http://msdn2.microsoft.com/en-us/lib...ehashcode.aspx

I deleted temporary files which did not resolve the problem but the problem
has been resolved; I forgot to edit inheritence via the .aspx.


"Juan T. Llibre" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> re:
> I would find GetTypeHashCode and find out why it is not overriding
>
> It's a page compiler method :
>
> private void BuildGetTypeHashCodeMethod();
> Declaring Type: System.Web.Compilation.PageCompiler
>
> private void BuildGetTypeHashCodeMethod()
> {
> CodeMemberMethod method = new CodeMemberMethod();
> method.Name = "GetTypeHashCode";
> method.ReturnType = new CodeTypeReference(typeof(int));
> method.Attributes &= ~MemberAttributes.AccessMask;
> method.Attributes &= ~MemberAttributes.ScopeMask;
> method.Attributes |= MemberAttributes.Public |
> MemberAttributes.Override;
> base._sourceDataClass.Members.Add(method);
> method.Statements.Add(new CodeMethodReturnStatement(new
> CodePrimitiveExpression(this.Parser.TypeHashCode)) );
> }
>
>
>
>
> Juan T. Llibre, asp.net MVP
> asp.net faq : http://asp.net.do/faq/
> foros de asp.net, en espaņol : http://asp.net.do/foros/
> ======================================
> "Cowboy (Gregory A. Beamer)" <(E-Mail Removed)> wrote in
> message
> news:(E-Mail Removed)...
>> Not looking up anything, but I would find GetTypeHashCode and find out
>> why it is not overriding. I would also clear
>> out any temporary ASP.NET files, as that causes issues from time to time.
>> Once cleared, it uis usually fine.
>>
>> Here is my problem with Temporary ASP.NET files:
>> http://gregorybeamer.spaces.live.com/blog/cns!B036196EAF9B34A8!510.entry
>>
>> --
>> Gregory A. Beamer
>> MVP, MCP: +I, SE, SD, DBA
>>
>> Subscribe to my blog
>> http://gregorybeamer.spaces.live.com/lists/feed.rss
>>
>> or just read it:
>> http://gregorybeamer.spaces.live.com/
>>
>> *************************************************
>> | Think outside the box! |
>> *************************************************
>> "clintonG" <(E-Mail Removed)> wrote in message
>> news:%(E-Mail Removed)...
>>> namespace CompanyName
>>> {
>>> public partial class ...
>>> {
>>> ...
>>> }
>>> }
>>>
>>> Keeps failing when trying to use a namespace on a new web site. I've
>>> tried with page classes that inherit from
>>> System.Web.UI.Page, my own CommonBaseClass : System.Web.UI.Page, pages
>>> that inherit the CommonBaseClass and when
>>> using a MasterPage. I just keep getting the same error...
>>>
>>> // no idea what this implies...
>>> Compiler Error Message:
>>> CS0115: 'ASP.default_aspx.GetTypeHashCode()':
>>> no suitable method found to override

>>
>>

>
>
>


 
Reply With Quote
 
clintonG
Guest
Posts: n/a
 
      04-02-2008
You da man George. Thank you for reminding us we have to edit the .aspx on
..cs files we add the namespace to manually.

<%= Clinton


"George Ter-Saakov" <(E-Mail Removed)> wrote in message
news:%(E-Mail Removed)...
> Post here your <%@Page directive
>
> I think you inheriting there from class that does not exist...
>
> Must be something like
> Inherits="CompanyName._Defaul"
>
> George.
>
>
>
> "clintonG" <(E-Mail Removed)> wrote in message
> news:%(E-Mail Removed)...
>> namespace CompanyName
>> {
>> public partial class ...
>> {
>> ...
>> }
>> }
>>
>> Keeps failing when trying to use a namespace on a new web site. I've
>> tried with page classes that inherit from System.Web.UI.Page, my own
>> CommonBaseClass : System.Web.UI.Page, pages that inherit the
>> CommonBaseClass and when using a MasterPage. I just keep getting the same
>> error...
>>
>> // no idea what this implies...
>> Compiler Error Message:
>> CS0115: 'ASP.default_aspx.GetTypeHashCode()':
>> no suitable method found to override

>
>


 
Reply With Quote
 
George Ter-Saakov
Guest
Posts: n/a
 
      04-03-2008
You are welcome....
been there myself

George.



"clintonG" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> You da man George. Thank you for reminding us we have to edit the .aspx on
> .cs files we add the namespace to manually.
>
> <%= Clinton
>
>
> "George Ter-Saakov" <(E-Mail Removed)> wrote in message
> news:%(E-Mail Removed)...
>> Post here your <%@Page directive
>>
>> I think you inheriting there from class that does not exist...
>>
>> Must be something like
>> Inherits="CompanyName._Defaul"
>>
>> George.
>>
>>
>>
>> "clintonG" <(E-Mail Removed)> wrote in message
>> news:%(E-Mail Removed)...
>>> namespace CompanyName
>>> {
>>> public partial class ...
>>> {
>>> ...
>>> }
>>> }
>>>
>>> Keeps failing when trying to use a namespace on a new web site. I've
>>> tried with page classes that inherit from System.Web.UI.Page, my own
>>> CommonBaseClass : System.Web.UI.Page, pages that inherit the
>>> CommonBaseClass and when using a MasterPage. I just keep getting the
>>> same error...
>>>
>>> // no idea what this implies...
>>> Compiler Error Message:
>>> CS0115: 'ASP.default_aspx.GetTypeHashCode()':
>>> no suitable method found to override

>>
>>

>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
having problems with wireless connection =?Utf-8?B?THVpemFv?= Wireless Networking 1 09-24-2005 04:48 AM
overloaded operators and namespaces compile problems George Economos C++ 4 08-23-2005 05:07 PM
XPath expressions having namespaces gimme_this_gimme_that@yahoo.com XML 1 04-20-2005 05:03 AM
Problems. Transformation and namespaces. Pablo XML 1 01-28-2005 03:49 PM
Having Problems with Message Rules and Dictionary Install. Reg Mouatt Firefox 7 10-04-2004 11:58 PM



Advertisments