Last week I wrote a small C# application in Microsoft Visual C#2010 Express. The application will help to script the indexes from any server and can filter on clustered or non-clustered indexes. I published the application and wanted my colleague to run it from his machine.
I searched for the error and tried a lot of stuffs as different posts suggested different things and nothing works. I then decided to play with Visual Studio and checked the properties. The properties of a solution will look like below.
I noticed that there is this option called Application files. I checked the application files and was able to see the dll which is mentioned in the error. There was an option “Publish Status” and it was set as exclude. I changed this to Include.
Once I changed this setting I published my application once more and this time It opened up the application rather than giving an error.