473,386 Members | 1,720 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,386 software developers and data experts.

Problem with Default Namespaces in VS2005 in C#

Hi All,

Having a problem transitioning from VS2003 to VS2005 in C#. Probably a
really simple answer.

Basically when I'm creating a class library, rather than wrap every class in
namespace MyNamespace {}, I usually go to the project properties and set the
default namespace to some namespace, for example MyNamespace. When I then
come to use this class library from another application (eg
WindowsApplication1), I set a reference to this project in the references.
So far so good.

As I remember it in VS2003, you would need to use the 'using' keyword or
fully specify the namespace before the class, eg using MyNamespace or
MyNamespace.Class1. However for some reason in VS2005 it is allowing me to
just use Class1. The presents a big problem if two assemblies I refer to
each have a class named Class1.

How can I force the developer to fully qualify the Namespace?


Nov 17 '05 #1
0 1060

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

Similar topics

1
by: John L. Clark | last post by:
I am curious as to the rationale, and effect, of having default namespaces not applying (directly) to attributes (see http://www.w3.org/TR/REC-xml-names/#defaulting). Given an attribute without a...
5
by: Alexis | last post by:
Hello, I have a set of classes I created from schema files using the xsd.exe tool. I'm using namespaces in the clases ( I had to because I have some classes with the same name but not the same...
6
by: Martin | last post by:
Hi, I have a xml file like the one below <?xml version="1.0" encoding="utf-8"?><e1 xmlns:e1="http://tempuri.org/Source1.xsd" e1:att1="1" e1:att2="2" e1:rest="345"/> If I try to create a...
3
by: Steven Fox | last post by:
============================================================ About DB2 Administration Tools Environment ============================================================ DB2 administration tools level:...
2
by: clintonG | last post by:
Are developers still using namespaces in their code for pages or is this practice no longer neccessary for pages? I don't see the rationale here. except perhaps for controls that are comprised of...
10
by: Ole | last post by:
Hi, Using VS2005 and a windows CE 5.0 device running CF2. Suddenly I can't debug my C# program from VS2005 - when setting a breakpoint I only see a ring instead of the normal red dot and when...
4
by: Al Norman | last post by:
We have two separate DLLs that do not interact (directly, at least). One is an MFC extension DLL that was built back in VC++ 6 days (but has been recompiled with VS2005). The other is a DLL that...
4
by: noosaj | last post by:
Hello, I use vs2005 and I'm a college student studying programming. I'm currently enrolled in a visual basic programming class. I have one question, and I apologize if it sounds dumb. What...
0
by: Karel Kral | last post by:
Hello, I have medium-sized solution in VB.NET (70 000 lines). The project compiles ok under VS2005, without any errors, without any warnings. But when I compile the same solution under MSBuild...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
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
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
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...

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.