Does Windows Installer use Assembly Version or File Version to update dlls - .net-2.0

I have a .net (2.0) winforms application that I need to upgrade on client machines. At the moment this is done by incrementing the Assembly Version and File Version on all of the projects and incrementing the version on the Installer project in VS2008.
The application now makes use of Isolated Storage to save some user settings in an XML file (grid layouts etc...).
The problem I am now facing is that if I increment all the version numbers, the application has a new location for its Isolated Storage, because the File Version has changed. With a new location for isolated storage, all the settings have effectively been lost.
When upgrading does Windows installer replace the dlls based on the File Version or the Assembly Version?
If it is the Assembly Version then all I'd have to do is not increment the File Version.

Some good reading and discussion here:
http://social.msdn.microsoft.com/Forums/en-US/netfxbcl/thread/6ed4d384-f6e9-42ee-b485-0bf40d0abd65/
To answer your question, though, I believe that MSI's respect FileVersion primarily:
File Versioning Rules

Related

Compatibility with .NET Framework 3.5

I’m using, integrated in my software, List&Label 16 and now I would like to upgrade it to the version 24.
I have a couple of question:
I’m using, for historical reasons, .NET Framework 3.5, and I’m
building my Visual Studio project with this framework. Can anyone
confirm that List&Label 24 is fully compatible with .NET framework
3.5?
Opening the LL viewer and editor from my application I cannot save any file in the C:\Program FIles… folder of my application. Should I change the folder? Or there is some workaround to write in one folder under the path C:\Program files…?
Thanks to all
Regards
Yes, LL24 is fully compatible with .NET 3.5
Basically, this is a Windows question. The viewer can open files from whatever location you have access to. There are several APIs in the product (e.g. LlPreviewSetTempPath) to set the temporary path for printing and exporting. On Windows 10, the default of your app should be somewhere in the Documents path of the user

Detecting when assembly info version not updated

I'm using Git as my source control and team city for running builds which compile a .net code base using FAKE script.
We want to be able to detect as a build check if someone has changed a library without bumping the version number.
Not all changes in the repository will require a new version of a nuget package to be created, only if a library which is packaged changes its version number.
This approach has a human error element to it of changing the library, but forgetting to bump the version and therefore it not being published.

RedGate SQL Comparison SDK API Licensing Issue

First of all Sorry all that I have to write the lengthy question, But it is necessary to write these things to explain my problem better.
We have an installer to install our application. I want to upgrade the database through installer. So, I have created a snapshot of the latest structure database and placed in the package of the application. I have used the RedGate SQL Comparison SDK API to compare structure of two databases and then synchronize the customer database with the latest snapshot (which I have provided).
I am using custom action class library project to write the methods and those methods will be called the installer itself.
I have purchased the RedGate License key and also RedGate Tool is installed on one machine. On the same machine, I have a installshield license, So I am writing the custom action code on that machine only.
We need to add 'licenses.licx' file in the project where we are using the RedGate SDK API. I have added that file as mentioned in 'http://documentation.red-gate.com/display/CSD11/Distributing+your+SDK+applications'.
I have added that file and the compilation succeeded, as I have the license activated on the same machine. So, first of all to embed the license with the project I had deactivated the RedGate License from the installed RedGate and then While compiling the project I got a popup for activation as shown below:
I have applied the valid license, then I have compiled the installer project from installshield 2014 (which is using the custom action project).
My code of synchronizing the database is working as expected. So, I didn't found any problem in the synchronization code.
Here, the problem is: If I will install the product on the machine which have the Redgate License, then the product will be installed and database will be synchronized successfully. On the client machines, it is obvious that they would not have the RedGate license. The installer is giving the activation popup as shown in above image just before starting the synchronizing.
Even though I have given the valid license at the time of compiling the, I am not able to sync the dbs on other machines.
Hope, someone has a solution for this.
Thanks in anticipation.
Did you rename the assembly after compiling? The engine requires that the assembly file name is the same as the name of the embedded licence resource. Here's a quote from the relevant page in the documentation.
When deploying an assembly utilizing SQL Comparison SDK to a remote site where SQL Comparison SDK is not already installed and activated, you may be asked to activate the SDK, even though the assembly had been built and licensed correctly.
The problem occurs after renaming an assembly. SQL Comparison SDK assemblies cannot be renamed after they are built, because the licensing system requires the licence resource embedded into an assembly to bear the same name as the assembly file name.
You can either change the assembly back to its original name, or change the settings in your Visual Studio project so that the output assembly is compiles as a different name and deploy the assembly built with the desired name.

Migrate Enterprise Library 4.1 to 5.0

We are using enterprise library 4.1 and smart client software factory 2008 to our application.
how we can upgrade enterprise library 5.0 and SCSF 2010 to our application.presently we are using visual studio 2008.
To upgrade what are the thing needs to be taken care.
Early help would be appreciated.
In terms of Enterprise Library, the best case scenario would be to replace the 4.1 assembly references with 5.0 assembly references and change the configuration (to use 5.0 references instead of 4.1 references). However, you could also hit some issues.
You should read the Microsoft Enterprise Library 5.0 Migration Guide for a full description. The Breaking Changes document could also help you determine if you may run in to migration issues.
For the Smart Client Software Factory the approach appears the same: change the references and configuration to use the new dlls. The Web Client Software Factory 2010 Documentation download has a section on Migrating to Visual Studio 2010.
Install the 5.0 package.
remove all the previous refreneces and add the newer ones generated.
You can refer the dlls by copying it to some folders or directly from the location where you have installed (C:\programfiles\Microsoftenterpriselibrary5.0)
I faced the below issues while migrating
Configuration errors in web.config files - some of my references in the web.config files were refering to the older version(2.0.0.0)(i upgraded from 2.0 to 5.0) and the publictokenkey="null"
so i pushed all the dlls to the gac and added the publicktokenkey from the c:\windows\assembly. which solved the issue
And another issue was regarding the microsoft.practices.enterpriselibrary.caching.cryptography- it was displaying soem weird error.- solution-the bin folder was having the old dlls and when tried to
clean the solution the dll reference was still there. SO i deleted all those from the folder and rebuild again.
IT was initially having the logicacmg.enterpriselibraryextensions.logging which caused some issues- i used the microsoft.practices.enterpriselibrary.logging.configuration.rollingflatfiletracelistenerdata which could solve the issue.
Hope some one might get some inputs with this post

Why doesn't my Entity Framework app work on production server?

I get following error when deploying on test server with II6 and Framework 3.5 SP1 installed.
The located assembly's manifest
definition does not match the assembly
reference
My development machine is a 64bit pc with Visual Studio 2008.
Any suggestions?
Looks as though the .net assembly is unable to find the correct version that you are after. Make sure you put the assembly definition in the GAC. You may need to look at the GAC and remove the old version and then rebuild.
In other words, go to your production server and look for any assemblies (.dll files) that are currently loaded on that server. The version on your production server may not match the reference of your local machine's project.
Once you find it remove it and replace it with what your application is using.