p2p.wrox.com Forums

Need to download code?

View our list of code downloads.


Go Back   p2p.wrox.com Forums > ASP.NET and ASP > ASP.NET 1.0 and 1.1 > ASP.NET 1.0 and 1.1 Basics
I forgot my password Register Now
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 1.0 and 1.1 Basics ASP.NET discussion for users new to coding in ASP.NET 1.0 or 1.1. NOT for the older "classic" ASP 3 or the newer ASP.NET 2.0.

Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 1.0 and 1.1 Basics section of the Wrox p2p Programmer to Programmer discussion community. This is a community of more than 40,000 computer programmers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining our free Wrox p2p community you can post your own programming questions and respond to other programmers’ questions. Registered users also don't have to see the ads that are displayed to guests. Registration is fast, simple and absolutely free so please, join today!
Join today and post to win prizes! Post more to increase your chances of being Wrox’s top poster of the month.

Reply
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old December 3rd, 2003, 12:08 PM
Registered User
Points: 20, Level: 1
Points: 20, Level: 1 Points: 20, Level: 1 Points: 20, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2003
Location: London, London, United Kingdom.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default 'CreateResourceBasedLiteralControl' is not a membe

When I try to compile my application I get the following messages..! In a nunbver of places...and I havn't got a clue how to fix it or what it means..has anybody else had this message..?

'CreateResourceBasedLiteralControl' is not a member of 'ASP.SiteHeader_ascx'

I am using VS.Net 2003...

I can supply more details if anybody is willing to give me some assistance...! I t would be much appreciated...I have had 6 years of ASP experience but am just now crossing over to .NET...

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #2 (permalink)  
Old December 3rd, 2003, 05:44 PM
Authorized User
Points: 163, Level: 3
Points: 163, Level: 3 Points: 163, Level: 3 Points: 163, Level: 3
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Oct 2003
Location: , , Norway.
Posts: 45
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Have you just renamed a .ASP page to .ASPX?
or
Have you created an .ASPX file and then copied in .ASP code to it?

------------------------
All help is Good help!
Regards
Michael
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #3 (permalink)  
Old December 4th, 2003, 05:31 AM
Registered User
Points: 20, Level: 1
Points: 20, Level: 1 Points: 20, Level: 1 Points: 20, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2003
Location: London, London, United Kingdom.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi Michael...

Thanks for your reply..

No I havn't copied ASP code or renamed the file..

Here is the code for the page:

<%@ Control Language="vb" AutoEventWireup="false" Codebehind="SiteHeader.ascx.vb" Inherits="COLT.ThePhile.Web.Controls.User.SiteHead er" TargetSchema="http://schemas.microsoft.com/intellisense/ie5" %>
<link href="/msowa/thephile/Styles/ThePhile.css" rel="stylesheet">

<table width="100%" border="0" class="Site_Header">
    <tr>
        <td width="50%">
            <a href="/msowa/thephile/default.aspx">
                <img src="/msowa/ThePhile/images/ThePhile.gif" border=0 alt="ThePhile.COM">
            </a>
        </td>
    </tr>
</table>


and the code behind is: (I removed the auto generated region for clarity)

Namespace ThePhile.Web.Controls.User

 Public Class SiteHeader

    Inherits System.Web.UI.UserControl



    Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
                        System.EventArgs) Handles MyBase.Load
            'Put user code to initialize the page here
    End Sub

    End Class

End Namespace


The control is used like the following...

<%@ Register TagPrefix="COLTUserControl" TagName="SiteHeader" Src="Controls/User/Siteheader.ascx" %>


with a <COLTUserControl:SiteHeader id="Header" runat="Server" /> further into the page....

and that is on a normal web page default.aspx

This is all from the Wrox book I am working through...One thing that I did do was rename my namespace root....would this cause the error..? I started of using the Wrox namespace name but changed it to my company name....

I am actually thinking about starting from scratch....


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #4 (permalink)  
Old December 4th, 2003, 08:07 AM
Registered User
Points: 20, Level: 1
Points: 20, Level: 1 Points: 20, Level: 1 Points: 20, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2003
Location: London, London, United Kingdom.
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hey I've managed to find the solution...

When I checked the error detail and the full compile script, I noticed that the first error was giving me an error regarding my control, saying it couldn't load it because the name was ambiguous.

After much searching for a solution I stumbled accross it myself.

The controls, when the project is built, are compiled into a dll that sits in the bin (Default) directory of the website (in Inetpub) That is, i suppose if you are makign a web app, like I am. Anyway during the course of development I decided to change my namespace names. Therefore in this directory there was an old dll, and this had an older verison of the siteheader control I am trying to use, and therefore is giving the ambiguous error. I deleted this dll and re built my app and it worked...

Although now I have other troubles! Such is life...

Cheers

Mike

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #5 (permalink)  
Old May 27th, 2004, 08:09 PM
Registered User
Points: 4, Level: 1
Points: 4, Level: 1 Points: 4, Level: 1 Points: 4, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Dec 2003
Location: , , .
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hey i found the same problem,

what my problem was i was using a mixture of compiled dlls, and uncompiled vb files, and i had called my new class the same as one of the classes / subs in the other compiled dlls.



Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #6 (permalink)  
Old December 21st, 2005, 02:20 PM
Authorized User
 
Join Date: Jun 2005
Location: , , .
Posts: 11
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Same thing happened to me when i renamed my namespace, delete all the old dll's out of the bin folder recompiled and it started to work.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #7 (permalink)  
Old June 12th, 2007, 05:24 PM
Registered User
 
Join Date: Jun 2007
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I was getting a similar error but the reason was quite different. Initially I took some old code and was modifying it. I was getting error because I removed 'Public' from the class. So in details it said it was not able to access the class.
Also regarding rebuilding, its not required to delete the old .dll, just use 'Rebuild Project/Solution' option and it will be sufficient.

I was able to compile and successfully load my project because of you all who posted before. Thank you very much.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #8 (permalink)  
Old September 29th, 2007, 05:47 AM
Registered User
Points: 8, Level: 1
Points: 8, Level: 1 Points: 8, Level: 1 Points: 8, Level: 1
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2004
Location: , , .
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I ran into this same problem. I'm using VS 2005. I was accidentally trying to upload my files out of my 'Visual Studio 2005/Websites/[WebsiteNameHere]' folder. You are supposed be uploading the files from your 'Visual Studio 2005/Projects/[WebsiteNameHere]/Precompiled/[WebsiteNameHere]' folder.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #9 (permalink)  
Old December 4th, 2007, 10:56 PM
Registered User
 
Join Date: Dec 2007
Location: Bear, DE, USA.
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to educatedcg
Default

Make sure there are no classes or master pages that are duplicated in your project. The application may come but it won't fully work.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
  #10 (permalink)  
Old May 20th, 2008, 03:12 AM
Registered User
 
Join Date: May 2008
Location: , , .
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hi, about 'CreateResourceBasedLiteralControl' is not a member of 'ASP.SiteHeader_ascx', i found, one cause of this problem come from class visibility (relate to "access right" to this object at runtime). The error is disappear when i change visibilty from "Private" to "Public" in control class (*.ascx.vb)


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Reddit!
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off
Forum Jump



All times are GMT -4. The time now is 03:55 AM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
© 2008 Wiley Publishing, Inc