visual-studio-2008

Can you make a VC++ Solution set preprocessor #defines on loaded projects?

主宰稳场 提交于 2020-01-11 05:31:05
问题 I have a library which supports a #define to control how it's built. However the library can be used by multiple EXE projects which want different versions. Can I make the app/EXE project set the #define to be used by the library when built, or set it in the solution? The only other option I can think of is creating a separate build-configuration on the library project but that would quickly get out of control. That's common for e.g unicode/non-unicode builds but then you'd end up multiplying

Why are doubles added incorrectly in a specific Visual Studio 2008 project?

让人想犯罪 __ 提交于 2020-01-10 19:55:28
问题 Trying to port java code to C++ I've stumbled over some weird behaviour. I can't get double addition to work (even though compiler option /fp:strict which means "correct" floating point math is set in Visual Studio 2008). double a = 0.4; /* a: 0.40000000000000002, correct */ double b = 0.0 + 0.4; /* b: 0.40000000596046448, incorrect (0 + 0.4 is the same). It's not even close to correct. */ double c = 0; float f = 0.4f; c += f; /* c: 0.40000000596046448 too */ In a different test project I set

Visual Studio ASP.Net expand and collapse issue in ashx generic handlers

这一生的挚爱 提交于 2020-01-10 14:02:15
问题 I have Visual Studio 2008 Professional and I am having issues with expanding and collapsing method code blocks in ASP.Net Generic Handler pages (.ashx) I would have thought you could do the same thing like in the code behind of .aspx web pages. I have this same issue on other boxes even with VS 2008 Standard and VS 2005 Professional. All boxes have been fully patched (OS and Visual Studio.) Does anybody have any suggestions as to enabling this feature? 回答1: You can force Visual Studio to

Visual Studio ASP.Net expand and collapse issue in ashx generic handlers

夙愿已清 提交于 2020-01-10 14:01:35
问题 I have Visual Studio 2008 Professional and I am having issues with expanding and collapsing method code blocks in ASP.Net Generic Handler pages (.ashx) I would have thought you could do the same thing like in the code behind of .aspx web pages. I have this same issue on other boxes even with VS 2008 Standard and VS 2005 Professional. All boxes have been fully patched (OS and Visual Studio.) Does anybody have any suggestions as to enabling this feature? 回答1: You can force Visual Studio to

What is the best practice for compiling Silverlight and WPF in one project?

和自甴很熟 提交于 2020-01-10 10:24:19
问题 I've just completed a Silverlight project and it's time to have a little clean up. I'd like to take my core files and put them into a separate project which I will reference from my main Silverlight app. Some of these classes are compatible with WPF and I would quite like to be able to have Silverlight / WPF code all in one project. My ideal solution would be a single project that allows multiple configurations. So, Configuration: Silverlight would generate: Company.Controls.Silverlight.dll

What is the best practice for compiling Silverlight and WPF in one project?

无人久伴 提交于 2020-01-10 10:23:08
问题 I've just completed a Silverlight project and it's time to have a little clean up. I'd like to take my core files and put them into a separate project which I will reference from my main Silverlight app. Some of these classes are compatible with WPF and I would quite like to be able to have Silverlight / WPF code all in one project. My ideal solution would be a single project that allows multiple configurations. So, Configuration: Silverlight would generate: Company.Controls.Silverlight.dll

How do I specify Visual Studio Installer Conditions?

北战南征 提交于 2020-01-10 08:59:32
问题 I have a Visual Studio Installation Project and I want the Installer to create a specific folder only if a check box on a 'Checkboxes (A)' form that I've added to the project UI is checked. The name of the property for the checkbox is CHECKBOXA1 but I have no idea what to put in the Condition property of the folder so that it only gets created if the checkbox is checked. 回答1: In the 'Condition' property for your folder, place the following: CHECKBOXA1=1 This will make sure that the folder is

Visual Studio 2008 (C++) memory leak detection not showing file/method location - how to get that to work?

江枫思渺然 提交于 2020-01-10 08:33:51
问题 I am using the instructions found here to try to find memory leaks in a Win32 application. As described, I put the #define _CRTDBG_MAP_ALLOC #include <stdlib.h> #include <crtdbg.h> Lines at the top of a file (the cpp file that contains WINAPI _tWinMain) and then at the exit point of winmain I added _CrtDumpMemoryLeaks(); Unfortunately I do not see the line numbers/locations for the leaks (but I do get a list of leaks). I also tried putting _CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK

Visual Studio 2008 (C++) memory leak detection not showing file/method location - how to get that to work?

删除回忆录丶 提交于 2020-01-10 08:33:06
问题 I am using the instructions found here to try to find memory leaks in a Win32 application. As described, I put the #define _CRTDBG_MAP_ALLOC #include <stdlib.h> #include <crtdbg.h> Lines at the top of a file (the cpp file that contains WINAPI _tWinMain) and then at the exit point of winmain I added _CrtDumpMemoryLeaks(); Unfortunately I do not see the line numbers/locations for the leaks (but I do get a list of leaks). I also tried putting _CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK

Why is <table> not allowed inside <p>

ぃ、小莉子 提交于 2020-01-10 04:45:07
问题 Why can't <p> be nested inside <table> ? What is the correction I could make? Removing the <div> and <p> tags corrupt my design. As the website follows a client provided design. I have the following code and it works fine in VS2008, but I get warnings: <div class="right_articles"> <p> <table> <tr> <td> <img alt="Img not found" src="images/ribbon.gif" style="width: 155px; height: 125px;" /> </td> <td> <asp:Label ID="Label1" runat="server" Text="Label"></asp:Label><br /> <asp:Label ID="Label2"