473,614 Members | 2,428 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

No Namespace Specified - Where Do the Types Live?

I just converted an ASP.NET Web Site to be an ASP.NET Web Application
project type in Visual Studio 2005. After the conversion, the whole thing
still works - it builds and the Web app runs just fine. However, none of the
classes are placed explicitly in any namespace. The ASP.NET Web Site project
type apparentlyl infers namespace from the site's directory structure. But
Visual Studio's conversion process ("Convert to Web Application") does not
explicitly add any namespaces to any of the classes.

So, where do the classes live after the conversion? Is there some "default"
or "global" namespace into which the classes are placed? Just curious... I'm
not trying to solve any specific runtime problem here.

Thanks.
Nov 17 '08 #1
3 5484
re:
!So, where do the classes live after the conversion?

In the VS 2005 or 2008 IDEs, right-click your Project's name in the Solution Explorer,
select "Properties ", then click on the Application menu on the left.

In 2008, you'll see a textbox for the "default namespace";
in 2005, the textbox is named "root namespace".

Set them to whatever you'd like the default/root namespace to be.


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/
=============== =============== ========
"Johnson" <A@B.comwrote in message news:up******** ******@TK2MSFTN GP03.phx.gbl...
>I just converted an ASP.NET Web Site to be an ASP.NET Web Application project type in Visual Studio 2005. After the
conversion, the whole thing still works - it builds and the Web app runs just fine. However, none of the classes are
placed explicitly in any namespace. The ASP.NET Web Site project type apparentlyl infers namespace from the site's
directory structure. But Visual Studio's conversion process ("Convert to Web Application") does not explicitly add any
namespaces to any of the classes.

So, where do the classes live after the conversion? Is there some "default" or "global" namespace into which the
classes are placed? Just curious... I'm not trying to solve any specific runtime problem here.

Thanks.

Nov 17 '08 #2
On Nov 17, 10:50*am, "Johnson" <A...@B.comwrot e:
I just converted an ASP.NET Web Site to be an ASP.NET Web Application
project type in Visual Studio 2005. After the conversion, the whole thing
still works - it builds and the Web app runs just fine. However, none of the
classes are placed explicitly in any namespace. The ASP.NET Web Site project
type apparentlyl infers namespace from the site's directory structure. But
Visual Studio's conversion process ("Convert to Web Application") does not
explicitly add any namespaces to any of the classes.

So, where do the classes live after the conversion? Is there some "default"
or "global" namespace into which the classes are placed? Just curious... I'm
not trying to solve any specific runtime problem here.

Thanks.
Hi,

They will live inside teh namespace defined by your project.
Do this test, add a new webform and see where it place it, most
probably you will see the class beind declared inside the namespace as
you expected
Nov 17 '08 #3
On Nov 17, 11:24*am, "Juan T. Llibre" <nomailrepl...@ nowhere.com>
wrote:
re:
!So, where do the classes live after the conversion?

In the VS 2005 or 2008 IDEs, right-click your Project's name in the Solution Explorer,
select "Properties ", then click on the Application menu on the left.

In 2008, you'll see a textbox for the "default namespace";
in 2005, the textbox is named "root namespace".

Set them to whatever you'd like the default/root namespace to be.

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/
=============== =============== ========
Hi Juan,

Nice seeing you around, been a while since we last talked to each
other.
Hope everything is ok with you.
cheers,
Ignacio.
Nov 17 '08 #4

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

Similar topics

3
4368
by: Kunle Odutola | last post by:
I have a database that tracks players for children's sports clubs. I have included representative DDL for this database at the end of this post. A single instance of this database supports multiple clubs. I would like to add support for letting each club define and store custom information about arbitrary entities. Basically, allows the clubs to define custom entities (i.e tables) and associated custom attributes (i.e. fields) that may be...
2
9861
by: Edward Yang | last post by:
My XML document has a default namespace specified by xmlns="some_url". Here it is: <?xml version="1.0" encoding="utf-8" ?> <ssmproject name="sample" server="sql" xmlns="mailto:neo_in_matrix@msn.com?subject=ssmprjx" > <pr>
2
3991
by: Michal Januszczyk | last post by:
I have a very simple XML document. <SmtpGatewayRules xmlns="http://www.foo.com/schema.xsd"> <rules> <rule> </rule> </rules> </SmtpGatewayRules> When no xmlns is specified I can find rule element with calling: SelectSingleNode("//rule");
2
3663
by: Corne Rabe | last post by:
Hi all I've got a webservices that will be called by a delphi product. They have defined a soap message that they will use to call my webservice. A header snippet is found below: <soap:Header> <mm:TheHeader xmlns:mm="http://The URL"> <SomeValue>123</SomeValue> <AnotherValue>blabla</AnotherValue> </mm:TheHeader >
12
2829
by: Keith Patrick | last post by:
Can someone tell me the difference in terms of actual implications using: namespace MyNamespace { using System; class MyClass {...} } vs. using System;
6
2221
by: Grant Robertson | last post by:
I am relatively new to XML, though I have taught myself a lot in the past month. I keep seeing namespace names with multiple colons in them such as: "urn:oasis:names:tc:entity:xmlns:xml:catalog" but I can't find any information on exactly what that means. Is that a namespace defined within a namespace defined within a namespace? Are they all nested within the same XML file? Or if I know the URI for "urn" (which I presume is the...
4
1877
by: Andrew | last post by:
I am having an interesting namespace conflict. When we use a third party lib we create a company assembly for any descending classes to go in. I have simplified the problem into the example below. We are using the third party assembly Abc.Reports so we have an assembly called ComanyName.Abc. The problem is when I try to use the class Abc.Reports.Thing it tries to find it in CompanyName.Abc.Reports.Thing.
8
1060
by: tshad | last post by:
Using VS 2008, I have a project that uses the dll from another project. The Namespace is MyFunctions, with a class of DbObject. The beginning of the code is: *************************** Imports System Imports System.Data Imports System.Data.SqlClient Namespace MyFunctions
3
1299
by: Johnson | last post by:
I just converted an ASP.NET Web Site to be an ASP.NET Web Application project type in Visual Studio 2005. After the conversion, the whole thing still works - it builds and the Web app runs just fine. However, none of the classes are placed explicitly in any namespace. The ASP.NET Web Site project type apparentlyl infers namespace from the site's directory structure. But Visual Studio's conversion process ("Convert to Web Application") does...
0
8179
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, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
8576
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 tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8272
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 Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7050
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, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5538
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4049
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4119
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1712
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
1421
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.