473,407 Members | 2,546 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,407 software developers and data experts.

Error Message: BC30451: Name 'Utilities' is not declared.

Hi, I have a problem trying to load a page, sends me the
following error message:

Error Message: BC30451: Name 'Utilities' is not declared.
Line 50: </ DIV>
Line 51: <div id="side">
Line 52: <% = Utilities.createNavBar ()%>
Line 53: </ DIV>
Line 54: <div id="main">

I have already imported the class within the page as follows
<% @ Page Language = "VB" AutoEventWireup = "false"
CodeFile = "Default.aspx.vb" inherits = "maim"%>
<% @ Import namespace = "Utilities"%>

They also put directly into the class
Imports Utilities

But I still sending the same message, any suggestions.
Thanks You.
Don Quixote of Nicaragua.
Elder Soto
Aug 29 '08 #1
4 6799
On Aug 29, 7:34*pm, Don Quijote de Nicaragua <elders...@gmail.com>
wrote:
Hi, I have a problem trying to load a page, sends me the
following error message:

Error Message: BC30451: Name 'Utilities' is not declared.
Line 50: </ DIV>
Line 51: <div id="side">
Line 52: <% = Utilities.createNavBar ()%>
Line 53: </ DIV>
Line 54: <div id="main">

I have already imported the class within the page as follows
<% @ Page Language = "VB" AutoEventWireup = "false"
CodeFile = "Default.aspx.vb" inherits = "maim"%>
<% @ Import namespace = "Utilities"%>

They also put directly into the class
Imports Utilities

But I still sending the same message, any suggestions.
Thanks You.
Don Quixote of Nicaragua.
Elder Soto
Do you have the appropriate DLL in the BIN folder?
Aug 29 '08 #2

Hi, I continue to get the same errror, I am following the steps:
If anyone has any comment ?.
1. add the reference
<%@ import namespace="Utilities"%>

2. Create Literal Control
<div id="side">
<asp:Literal ID="Literal1" runat="server"></asp:Literal>
</div>

3. Load the Control
Imports Utilities
Partial Class _Default
Inherits System.Web.UI.Page
Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load
Literal1.Text = Utilities.createNavBar
End Sub
End Class

4. Appear error:
Compiler Error Message: BC30451: Name 'Utilities' is not declared.
Source Error:
Line 4:
Line 5: Protected Sub Page_Load(ByVal sender As Object, ByVal e As
System.EventArgs) Handles Me.Load
Line 6: Literal1.Text = Utilities.createNavBar
Line 7: End Sub
Line 8: End Class

Thank You.
Don Quijote de Nicaragua.
Elder Soto.

My Complete Class:

Imports Microsoft.VisualBasic
Public Class Utilities
Private Shared nl As String = Environment.NewLine
Public Shared Function createNavBar() As String
Dim sHtml As String
sHtml = "<ul>" & nl
sHtml &= "<li class='tmli'>Men&uacute Principal</li>" & nl
sHtml &= "<li><a href='maim.aspx' style='color:Black'>Inicio</a></li>"
& nl
sHtml &= "<li class='tmli'>Atenci&oacute;n al Cliente</li>" & nl
sHtml &= "<li><a href='lstQrc.aspx' style='color:Black'>Lista Quejas/
Reclamos</a></li>" & nl
sHtml &= "<li><a href='lstRemisiones.aspx'
style='color:Black'>Remisiones</a></li>" & nl
sHtml &= "<li class='tmli'>Cat&oacute;logos</li>" & nl
sHtml &= "<li><a href='lstClientes.aspx' style='color:Black'>Clientes</
a></li>" & nl
sHtml &= "<li><a href='lstCatalogs.aspx?bAction=1'
style='color:Black'>Transporte</a></li>" & nl
sHtml &= "<li><a href='lstCatalogs.aspx?bAction=2'
style='color:Black'>Productos</a></li>" & nl
sHtml &= "<li><a href='lstCatalogs.aspx?bAction=3'
style='color:Black'>Quejas</a></li>" & nl
sHtml &= "<li><a href='lstPaises.aspx?bAction=4'
style='color:Black'>Pa&iacute;ses</a></li>" & nl
sHtml &= "<li><a href='lstAreas.aspx?bAction=5'
style='color:Black'>Areas</a></li>" & nl
sHtml &= "<li class='tmli'>Informes</li>" & nl
sHtml &= "<li><a href='rptCatalogosIU.aspx'
style='color:Black'>Cat&aacute;logos</a></li>" & nl
sHtml &= "<li><a href='rptRemisionesIU.aspx'
style='color:Black'>Remisiones</a></li>" & nl
sHtml &= "<li><a href='rptQrcIU.aspx' style='color:Black'>Quejas/
Reclamos</a></li>" & nl
sHtml &= "</ul>" & nl
Return (sHtml)
End Function
End Class
On 29 ago, 15:37, Alexey Smirnov <alexey.smir...@gmail.comwrote:
On Aug 29, 7:34 pm,DonQuijotede Nicaragua <elders...@gmail.com>
wrote:
Hi, I have a problem trying to load a page, sends me the
following error message:
Error Message: BC30451: Name 'Utilities' is not declared.
Line 50: </ DIV>
Line 51: <div id="side">
Line 52: <% = Utilities.createNavBar ()%>
Line 53: </ DIV>
Line 54: <div id="main">
I have already imported the class within the page as follows
<% @ Page Language = "VB" AutoEventWireup = "false"
CodeFile = "Default.aspx.vb" inherits = "maim"%>
<% @ Import namespace = "Utilities"%>
They also put directly into the class
Imports Utilities
But I still sending the same message, any suggestions.
Thanks You.
DonQuixote of Nicaragua.
Elder Soto

Do you have the appropriate DLL in the BIN folder?
Aug 31 '08 #3
On Aug 31, 2:30*am, Don Quijote de Nicaragua <elders...@gmail.com>
wrote:
Hi, I continue to get the same errror, I am following the steps:
If anyone has any comment ?.

1. add the reference
<%@ import namespace="Utilities"%>
.............
>
My Complete Class:

Imports Microsoft.VisualBasic
Public Class Utilities
"Utilities" is a name of the class and not the namespace, right?

@Import needs the name of the namespace.
http://msdn.microsoft.com/en-us/library/eb44kack.aspx
Aug 31 '08 #4
Yes is the name of the class, how i can declare my namespace in my
class utilities
Thank You.
Don Quijote de Nicaragua.
Elder Soto.

On 31 ago, 04:03, Alexey Smirnov <alexey.smir...@gmail.comwrote:
On Aug 31, 2:30*am,DonQuijotede Nicaragua <elders...@gmail.com>
wrote:
Hi, I continue to get the same errror, I am following the steps:
If anyone has any comment ?.
1. add the reference
<%@ import namespace="Utilities"%>

............
My Complete Class:
Imports Microsoft.VisualBasic
Public Class Utilities

"Utilities" is a name of the class and not the namespace, right?

@Import needs the name of the namespace.http://msdn.microsoft.com/en-us/library/eb44kack.aspx
Aug 31 '08 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: selena | last post by:
I have created 2 ASP pages that gives users the option of switching back and forth between French and English. They click on the word English and it converted the text to English and the French...
2
by: TJS | last post by:
it says the name is not declared, but it is how can I fix this ? Compiler Error Message: BC30451: Name 'arrReportsList' is not declared. ========================== if...
0
by: tshad | last post by:
I have an error routine in my Global.asax that gives me a different message than asp.net when you let it give you the error page. My error routine looks like: ...
10
by: Zak | last post by:
I've been working on converting one of the major sites in my company to ASP. net. I started with the migration assistant from Microsoft, which may or may not have been a good idea. It worked OK...
1
by: SinCity | last post by:
I get this error message: BC30451: Name '__w' is not declared And here is my code... script language="javascript"> document.form1.PageUrl.value='<%=Request.ServerVariables("HTTP_REFERER")%>';...
0
by: saleng | last post by:
Any idea? I have Exam.vb and aspx page: <!------------ Exam.vb start //----------------------------> Imports System.Data Module Exam Public Function DataLoad() As ICollection Dim...
0
by: guy | last post by:
I am New to ASP.Net 2.0 . For the last few days I have been writing some simple code . The problem is when I tried to debug my program I got an error message : Compile error message :BC 30451:...
14
by: JimN1 | last post by:
Hi, I am getting the following error message when I execute my query. I am trying to get my results in XML Explicit format. The error message is:Name cannot begin with the '.' character, hexadecimal...
3
by: marylipscomb | last post by:
I have a question about my asp.net application. It tells me that Name 'lblMessage' is not declared. Description: An error occurred during the compilation of a resource required to service this...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.