Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > .NET > .NET 4 and Visual Studio 2010 > .NET 4 and Visual Studio 2010 General Discussions
Password Reminder
Register
| FAQ | Members List | Search | Today's Posts | Mark Forums Read
.NET 4 and Visual Studio 2010 General Discussions For discussing anything about .NET 4, WPF, WCF, the rest of the .NET 4 Framework, and Visual Studio 2010 that isn't about a specific Wrox book. Please post code questions about a specific language (C#, VB, ASP.NET, etc) in the correct language forum instead.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the .NET 4 and Visual Studio 2010 General Discussions section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developers’ questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old October 21st, 2010, 10:06 AM
Friend of Wrox
Points: 2,876, Level: 22
Points: 2,876, Level: 22 Points: 2,876, Level: 22 Points: 2,876, Level: 22
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Denver, CO, USA.
Posts: 428
Thanks: 57
Thanked 2 Times in 2 Posts
Default Can't compile Windows Release version?

I can change the Compile Configuration to Release, and it compiles, but it keeps putting the result in the bin\Debug\ folder instead of bin\Release\, even though bin\Release\ appears in the Build output path. If I close the Project Properties and reopen it, the Configuration is reset to Active (Debug).

Does anybody have any suggestions on what may be causing this problem and how to fix it?
  #2 (permalink)  
Old October 23rd, 2010, 06:40 AM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Hi Ron,

Maybe you're just switching the configuration settings from Debug to Release and not the actual compilation setting? On the Properties dialog for a project, switching between the two just enables you to choose a build configuration to configure. To switch the actual build config from Debug to Release for compilation, not configuration, switch it using the Properties Grid for your entire Solution in the Solution Explorer.

Hope this helps,

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
The Following User Says Thank You to Imar For This Useful Post:
Ron Howerton (February 22nd, 2013)
  #3 (permalink)  
Old October 25th, 2010, 11:38 AM
Friend of Wrox
Points: 2,876, Level: 22
Points: 2,876, Level: 22 Points: 2,876, Level: 22 Points: 2,876, Level: 22
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Denver, CO, USA.
Posts: 428
Thanks: 57
Thanked 2 Times in 2 Posts
Default

My Solution Explorer lists these files currently:

CopyDBContents
My Project
clsDevDB.vb
clsProdDB.vb
frmCopyDB.vb

I right-click on CopyDBContents above, and select Properties from the menu. Whether this is the SOLUTION properties window or the PROJECT properties window is not clear from the window, but as it is the highest file in the soluton hierarchy, I've been working with the assumption it's the solution. In any case, the window opened when I do this lists these tabs:

Application
Compile
Debug
References
etc.

I select the Compile tab and the Configuration setting defaults to "Active (Debug)". I have changed this to "Release" and then selected "Rebuild CopyDBContents", which as I understand it, ought to create a new executable and all supporting files in the Bin\Release folder. Indeed, bin/Release is displayed in the Build Output Path when I select Configuration: Release. Yet I consistently get a new build with today's date and time in the Bin/Debug folder. Furthermore, VS confirms it's writing the exe to the Bin/Debug folder despite the explicit reference to bin\Release in Bild Output Path:

------ Rebuild All started: Project: CopyDBContents, Configuration: Debug x86 ------
CopyDBContents -> D:\Projects\2010\CopyDBContents\CopyDBContents\bin\Debug\CopyDBContents.exe
========== Rebuild All: 1 succeeded, 0 failed, 0 skipped ==========

Bin/Release is still empty. And as I said earlier, if I close the Properties tab and then reopen it, "Active (Debug)" is selected again, as though the change was not recorded.

Right-clicking on My Project opens a menu containing only the option "Open", which appears to open the very same window as right-clicking CopyDBContents and selecting Properties. I've tried changing the setting in both instances of these apparently identical setting pages with no effect. There appears to be no difference between Solution and Project settings in this instance.

Does that sound like I am changing Solution settings to you. If not, how do I find the solution settings if the steps above are not correct?
  #4 (permalink)  
Old October 25th, 2010, 01:01 PM
Imar's Avatar
Wrox Author
Points: 72,073, Level: 100
Points: 72,073, Level: 100 Points: 72,073, Level: 100 Points: 72,073, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,587 Times in 1,563 Posts
Default

Quote:
Does that sound like I am changing Solution settings to you.
Nope... ;-

Quote:
I right-click on CopyDBContents above, and select Properties from the menu.
When you right-click a project, you bring up the *Property Pages* or *Properties Dialog* for the project. When you switch from Debug to Release there, all you do is load the settings in the current dialog so you change the settings for the different build configurations. You can't change the actual active build config there.

What you need instead is the *Properties Grid* for the solution (The Properties Grid is the same grid you use to manage files, properties of controls and so on.) To change the settings for the solution, try this:

1. First, make sure you always show the solution node. VS hides that by default in single project solutions. Choose Tools | Options | Project and Solutions and then make sure that Always Show Solution is checked.

2. Next, in the Solution Explorer, click the solution (left) and press F4. This opens or puts focus on the Properties Grid.

3. Switch the Active Config to Release.

4. Build.

Alternatively, choose Build | Configuration Manager. There you can switch the Active Solution Configuration as well.

Hope this helps,

Imar
__________________
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Follow me on Twitter

Author of Beginning ASP.NET 4.5 : in C# and VB, Beginning ASP.NET Web Pages with WebMatrix
and Beginning ASP.NET 4 : in C# and VB.
Did this post help you? Click the button below this post to show your appreciation!
The Following User Says Thank You to Imar For This Useful Post:
Ron Howerton (February 22nd, 2013)
  #5 (permalink)  
Old October 25th, 2010, 01:12 PM
Friend of Wrox
Points: 2,876, Level: 22
Points: 2,876, Level: 22 Points: 2,876, Level: 22 Points: 2,876, Level: 22
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Denver, CO, USA.
Posts: 428
Thanks: 57
Thanked 2 Times in 2 Posts
Default

That did it, thanks! It was not apparent the Solution was being hidden (TYVM, MS!)
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
debug vs. release xagutxu Visual C++ 0 September 16th, 2009 07:46 AM
c# windows App: Copy Rights Version Dotnet 2005 winbala .NET Framework 2.0 2 April 7th, 2008 04:02 AM
debug version of 1.37 release? bobarnold BOOK: Beginning Cryptography with Java 1 October 12th, 2007 06:28 PM
Release problem jeusdi .NET Framework 1.x 0 February 27th, 2007 11:19 AM



All times are GMT -4. The time now is 08:03 PM.


Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.