If I understand you correctly, you want to query an actual Visual Studio
project file from a C# program to find the root namespace. The project files
are just XML, so standard XML navigation techniques will do. Here is a
section from one of my project files...
<VisualStudioProject>
<CSHARP
ProjectType = "Local"
ProductVersion = "7.10.3077"
SchemaVersion = "2.0"
ProjectGuid = "{95A4FAE0-6708-4770-93EC-E3BC70481F9A}"
<Build>
<Settings
ApplicationIcon = "App.ico"
AssemblyKeyContainerName = ""
AssemblyName = "EmulatorSuite"
AssemblyOriginatorKeyFile = ""
DefaultClientScript = "JScript"
DefaultHTMLPageLayout = "Grid"
DefaultTargetSchema = "IE50"
DelaySign = "false"
OutputType = "Exe"
PreBuildEvent = ""
PostBuildEvent = ""
RootNamespace = "EmulatorSuite.Executable"
RunPostBuildEvent = "OnBuildSuccess"
StartupObject = ""
It's the root namespace node you need to access. Can I ask why you would
need to do this?
--
Regards,
Tim Haughton
Agitek
http://agitek.co.uk http://blogitek.com/timhaughton
"Patrick Blackman" <ca*******@vl.videotron.ca> wrote in message
news:%2****************@TK2MSFTNGP14.phx.gbl...
How do you determine the default namespace of a project using code?