VC++08 make MFC apps DPI aware without updating VC++ - visual-c++

I may not have the option to simply update to a more recent VC++ version as would be ideal - the project is big and the update could break a lot of things, plus my lead may tell me not to pursue this. I'm wondering if anybody knows of a means by which an MFC app written using VC++08 can check resolution during runtime?

Thank you, #IInspectable for providing the answer I needed. A full update is not needed. DPI awareness can be activated via the app's manifest file. The link they provided was invaluable. Should anybody else have this issue and is using vs2008, if you cannot find the manifest file in the same dir as your exe after building, chances are, vs2008 has embedded the manifest in the exe. You can change this by opening the project's properties, going to manifest tool->IO. If you want to keep the manifest embedded, you can put your additional manifest info in a separate manifest file and provide the tool with the path of this file. The manifest tool will merge your manifest files.

Related

How to check if files exist in .ism without using InstallShield

I want to verify if certain exe files already exist in a merge module .ism (binary format). Is there a method of doing this without using InstallShield?
An *.ism file is really an MSI file with a changed extension. MSI files in turn are SQL databases stored as COM-structured storage files - a file system inside a single file with file streams for various content. This is the same format used in Office documents.
You can view MSI files with Orca from the Windows SDK: http://www.hass.de/content/how-install-microsoft-orca
Windows Installer XML (WiX) Deployment Tools Foundation (DTF) has an InstallPackage class available that exposes a FindFiles() method. This should be really easy to query the EXE. Just realize that being a merge module you won't know the full installation path as that's decided by the MSI generally.
Both of Chris's suggestions should work fine, as would using Orca. But it got me thinking there might be an even easier way using a tool called Merge Module Finder. It all depends on what you really want to do? Find files already in merge modules? Investigate what merge modules are in an Installshield file? It is not quite clear exactly what you want to do.
Though a bit clunky at times (I think the author hasn't updated it for the latest versions of Windows) it will help you look for a file in a bunch of merge modules interactively. You can also search for a registry value. Here is a screenshot:

Building application in Visual Studio 2012 always generates unwanted dll

I am making changes to a web forms application in visual studio 2012 and part of that change is to remove reference to an old dll. The dll is responsible for handling authentication and I have written a new class library to handle this.
My problem is everytime I build my website in the solution, it always generates this old dll. I've annotated out all references to it in the entire application and it's not in the project dependencies of the solution.
If I exclude the unwanted dll, it just generates a new one. I am completely baffled by this. It's something I've not encountered before so I am not sure what else I can do.
I'm not sure what to post so if anyone can help then that would be great.
I had a similar problem (but it was with a persistent DB file being generated). I ended up having to go through the bin from the project file and editing it from there. Some files are 'hidden' from the project, and are either visible by
Make sure you are showing all files. There is a button at the top of
the Solution Explorer called "Show All Files". To see this button,
make sure that your project is selected in the solution explorer.
or by manually going through your project files.
EDIT
It can sometimes be hidden in the Global Assembly Cache (GAC) where it can reside indefinitely. http://msdn.microsoft.com/en-us/library/zykhfde0.aspx explains how to remove it (if it is indeed hiding there).
try this, remove the old project from your Solution.

How to reference external aidl file in Android Studio

I have two projects that communicate using a .aidl file.
Using eclipse I could simply reference the source folder and all worked as expected.
How can I do that in 'Android Studio'?? It seems a simple task, but for the life of me, I haven't discovered how?
Any help would be greatly appreciated.
Note: the aidl file is not part of either project, it is referenced by both.
As pointed out in How to add link to file system in IntelliJ IDEA? there is no way to link to an external file in the way that eclipse allows.
What I did was to add the .aidl source to each project. I don't like doing this as it forces one to keep them in sync.
Now considering adding a dependency from one to the other.

How can I create and maintain machine-specific Visual C++ solution settings?

My team has been developing a software package for a while. The code is under source version control. Until now, every developer has been setting up their own development environment manually (we use Visual C++, recently upgraded to 2012). Now that the structure of the project has grown more complicated and the build configuration is non-trivial, I decided to create a portable solution and add it to the source control system for the convenience of newcomers.
The problem is I need the developers to be able to set up the solution according to their particular needs (mostly preprocessor #define's) without disturbing the solution for everybody else.
VC++ is creating a .user file for every project that seems to be designed to hold settings on a per-user basis, but I'm not sure how to add settings so they are stored in this file (which I exclude from source control) and not in the project file or the property sheet files (which are included in source control).
How can I accomplish this? Thanks.

How do I add a project to CruiseControl.NET?

I am looking at the cruisecontrol web dashboard. I can see one farm and one server. However, I don't see any way to add a project?
Is this something I can do with the UI or do I need to edit the config file by hand?
You'll need to edit the ccnet.config file by hand (located within the CruiseControl directory) to add projects. There are some graphical tools to help you do this however you do get used to doing it by hand fairly quickly - just have the documentation near by!
Update: An example of one such tool is http://www.codeplex.com/ccnetconfig
You can use CCNETConfig to edit the config file through an UI although it doesn't support higher version > CruiseControl.NET 1.4.
You have to basically edit the configuration file by hand, however I have it setup so that the raw config file is split into different include files, each of which is setup in my source control system. Then I created a project for the configuration, and then for the whole config. So when something changes in the config, CC.NET itself pulls out the changes, recreates it's config files and the refreshes the system configuration.
This means that anyone can edit the config (if they can access the files in sourcecontrol), and no-one has to go into the program files directory of the CC.NET machine itself.
Not sure whether this answers the question you asked, but this is how our setup works

Resources