473,326 Members | 2,655 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,326 software developers and data experts.

Ambiguous In Mamespace?

Consider the following code in a VB class file:

Namespace LoginUserFetchDB
Public Class ZForZebra : Inherits SoapHeader
Public UserName As String
Public Password As String
End Class

Public Class GetDBRecords : Inherits WebService
Private sqlCmd As SqlCommand
Private sqlConn As SqlConnection
Public sHeader As ZForZebra
...............
...............
End Class
End Namespace

Using VBC. I compiled the above in LoginUserFetchDB.dll which resides
in the folder C:\inetpub\wwwroot\ASPX\bin

Have a look at the line

Public sHeader As ZForZebra

Though the above code & the ASPX page which uses the above DLL works
without any problems, what I find is Visual Web Developer 2005 Express
Edition underlines the word 'ZForZebra' saying that

'ZForZebra' is ambiguous in the namespace 'LoginUserFetchDB'.

That's the reason why I used such an absurd class name 'ZForZebra'
since I am pretty sure that the .NET Framework won't be having any such
class name. Neither have I used such a class name in any of my class
files (or any other .NET related files) any time. I also tried using

Public sHeader As LoginUserFetchDB.ZForZebra

but that didn't make any difference.

After a lot of research, using the Object Browser, I concluded that
LoginUserFetchDB.dll not only exists in the above-mentioned bin
directory, it also exists at 2 more places:

C:\WINNT\Microsoft.NET\Framework\v2.0.50727\Tempor ary ASP.NET
Files\aspx\98099ba2\_shadow\695771b\bin\2\

&

C:\WINNT\Microsoft.NET\Framework\v2.0.50727\Tempor ary ASP.NET
Files\aspx\443e485a\_shadow\ff53954a\bin\2\

It was only when I deleted LoginUserFetchDB.dll from the above 2
folders did VWD 2005 stop highlighting this ambiguous name error.

Though I don't think that's could be the reason why VWD is highlighting
that error since in other VB class files using similar code, VWD
doesn't highlight the error. So how do I avoid the ambiguous name error
in VWD?

I don't understand what's causing the ambiguous error since I am more
than 100% sure that I am/have not used a class with the name
'ZForZebra' anytime anywhere!

Oct 13 '06 #1
1 1504
No one to help me resolve this problem? Never thought that this would
turn out to be such a tough question to answer considering the fact
that usually the .NET MVPs, experts & gurus are the ones who offer
solutions!!!
rn**@rediffmail.com wrote:
Consider the following code in a VB class file:

Namespace LoginUserFetchDB
Public Class ZForZebra : Inherits SoapHeader
Public UserName As String
Public Password As String
End Class

Public Class GetDBRecords : Inherits WebService
Private sqlCmd As SqlCommand
Private sqlConn As SqlConnection
Public sHeader As ZForZebra
...............
...............
End Class
End Namespace

Using VBC. I compiled the above in LoginUserFetchDB.dll which resides
in the folder C:\inetpub\wwwroot\ASPX\bin

Have a look at the line

Public sHeader As ZForZebra

Though the above code & the ASPX page which uses the above DLL works
without any problems, what I find is Visual Web Developer 2005 Express
Edition underlines the word 'ZForZebra' saying that

'ZForZebra' is ambiguous in the namespace 'LoginUserFetchDB'.

That's the reason why I used such an absurd class name 'ZForZebra'
since I am pretty sure that the .NET Framework won't be having any such
class name. Neither have I used such a class name in any of my class
files (or any other .NET related files) any time. I also tried using

Public sHeader As LoginUserFetchDB.ZForZebra

but that didn't make any difference.

After a lot of research, using the Object Browser, I concluded that
LoginUserFetchDB.dll not only exists in the above-mentioned bin
directory, it also exists at 2 more places:

C:\WINNT\Microsoft.NET\Framework\v2.0.50727\Tempor ary ASP.NET
Files\aspx\98099ba2\_shadow\695771b\bin\2\

&

C:\WINNT\Microsoft.NET\Framework\v2.0.50727\Tempor ary ASP.NET
Files\aspx\443e485a\_shadow\ff53954a\bin\2\

It was only when I deleted LoginUserFetchDB.dll from the above 2
folders did VWD 2005 stop highlighting this ambiguous name error.

Though I don't think that's could be the reason why VWD is highlighting
that error since in other VB class files using similar code, VWD
doesn't highlight the error. So how do I avoid the ambiguous name error
in VWD?

I don't understand what's causing the ambiguous error since I am more
than 100% sure that I am/have not used a class with the name
'ZForZebra' anytime anywhere!
Oct 13 '06 #2

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

Similar topics

16
by: REH | last post by:
Can some tell me why the chooses the constructor in class B over operator B in class A? Is this not ambiguous? Thanks. #include <iostream> using namespace std;
1
by: Alan Johnson | last post by:
Consider the following code, with the interesting lines numbered in comments: class A { public : bool f(int level = 1) // line 5 { return true ; }
9
by: xuatla | last post by:
compile error: test1.cpp:21: error: ISO C++ says that `T mtd::CDiffOperator::getdp(const mtd::mVector&, long int, mtd::mBCTYPE) const' and `void mtd::CDiffOperator::getdp(mtd::mVector&, const...
1
by: Alex Zhitlenok | last post by:
Hi, My question is how to resolve in C# ambiguous overloaded operators? Let say, I have two unrelated classes A and B, each one implements overloaded operator + with the first parameter of type...
9
by: Prasad | last post by:
HI, I am a beginner in VC++.. I am trying to write a Win32 console application in visual studio.. I am using following header files.. #include <STRING> using namespace std; #include...
3
by: Arpan | last post by:
The following code exists in a class file named "Users.vb": Namespace Users Public Class UserDetails Public FirstName As String Public LastName As String Public UserName As String Public...
8
by: xtrigger303 | last post by:
Hi to all, I'm working on a smart pointer implementation and I'm trying to get automatic type conversion between different pointer types. I stumbled upon something weird (at least for me) I...
12
by: Nathan Sokalski | last post by:
I have several CustomControls that I have written for my project. However, when I try to compile I recieve the following warning & errors: Warning 32 Could not resolve this reference. Could not...
3
by: i3x171um | last post by:
To start off, I'm using GCC4. Specifically, the MingW (setjmp/longjmp) build of GCC 4.2.1 on Windows XP x64. I'm writing a class that abstracts a message, which can be either an integer (stored as...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.