Configurations, do they work properly?

  • Thread starter Thread starter Claire
  • Start date Start date
C

Claire

I've been trying to create this "deploy" configuration and I've had to keep
deleting it then recreating again for one reason or another.

I assumed that deriving it from the "release" configuration ,when I create
it in configuration manager, would copy the exact settings across to my new
"deploy" configuration.
When I look at a project's Build and Advanced properties (from a selected
project's properties\configuration screen) I expect to see all the fields as
copies of the "release" configuration but they're not.
On top of that, older configurations that I deleted a while ago, appear in
the "Configuration" combo box at the top of the project property page.

Is there any way I can delete old configurations completely so that I can
start again with a clean sheet?

Claire
 
Yes,
If I create a completely new configuration with a new name and copy it from
the "release" configuration then all my settings are correct and my solution
builds with no problems.
So it looks as if once you create a configuration, then even if it's deleted
from config manager, the old data isn't overwritten and it's there waiting
to break your program at another time. This is a real nuisance as I just
want to call my deployment "deploy" and not have to think of different
names.
 
You could try manually editing the *.sln and *.csproj in Notepad. I know this
doesn't make it any easier, but you can use the same name then.

READ: I haven't tried it, so be sure to make a backup. Here are the sections
that I see that you may need to delete.

In The *.csproj

<Config
Name = "Debug"
AllowUnsafeBlocks = "false"
BaseAddress = "285212672"
CheckForOverflowUnderflow = "false"
ConfigurationOverrideFile = ""
DefineConstants = "DEBUG;TRACE"
DocumentationFile = ""
DebugSymbols = "true"
FileAlignment = "4096"
IncrementalBuild = "false"
NoStdLib = "false"
NoWarn = ""
Optimize = "false"
OutputPath = "bin\Debug\"
RegisterForComInterop = "false"
RemoveIntegerChecks = "false"
TreatWarningsAsErrors = "false"
WarningLevel = "4"
/>

In The *.sln

{365B5639-E9E2-4236-A24A-EA4EDEEE03D7}.Debug.ActiveCfg = Debug|.NET
{365B5639-E9E2-4236-A24A-EA4EDEEE03D7}.Debug.Build.0 = Debug|.NET

Once again, I haven't tried it, so be carfeul and make backups. Also, let us
know how it worked.

-Josh
 
Thanks Josh.
It's my "deploy" configuration that's at fault btw. Aside from that, I did a
search through the .sln file and only found the "Debug","Release" and
"DeployComms" configurations (these I hoped would be there). There was no
"deploy"
In the .csproj file however I found that "Deploy", "DeployVersion" and
"DeployComms" were all present despite previously deleting "Deploy" and
"DeployVersion" configurations. So I deleted these sections manually and it
all works ok. Thanks Josh.

I still had a problem tho'. The 3 configs in my solution built fine but I
still wanted my configuration to be named "deploy". So I created another
one, telling it to copy the "release" configuration. I got build errors that
I don't get in the other configs. They're errors about needing to be built
in unsafe mode or that I need to add references to certain assemblies. My
"DeployVersion" config was created in the same way and works fine. Anyway, I
renamed "DeployVersion" to "Deploy" and I'm happy.
 
Hello,

I wish to automate the generation of .sln & .vcproj files.

To this end I am looking for descriptions of the file formats and their
associated schemas for VS 2003.

I have tried to find this kind of information in the MSDN library and
have also tried the online chat

support but to no avail.

Any help will be greatly appreciated.
 
No, it didn't work properly in the end. I think the user configurations are
copied across to all .csproj files and they've lost synchronization with
each other. Im sure M/S have a good reason for doing it like this but it
doesn't work reliably.

thanks anyway.
 
Back
Top