Thursday, 16 April 2009

Inno Setup - a simple, free setup program

Another first when developing my C# application was considering how I was going to publish it.

Although there is a Publish tool in Visual Studio/C# and it seemed simple (with lots of extras - some of which I knew I would have to read up on) there was one issue I seemed to find hard to get around and much Googling seemed to show that other people were saying the same thing.

Inclusion of .NET download feature

Yes, how do you include this. There was talk about using Visual Studio (2008) Setup and Depolyment Templates - I followed one or two tutorials and soon gave up when I didn't seem to have any idea of where you could (or how you could) add the ability for the system not only to download the required .NET Framework but to check the users system to see if existed and if so then to bypass the download.

Several hours of searching online and reading peoples comments and thinking I was almost there I came to the conclusion that there seemed to be one Setup application that was a front runner when I found details (code) that would allow the users system to be checked before consdiering whether the .NET download was required.

Inno Setup

Inno Setup (Jordan Russell's Software) was the one that appeared to be the answer. Not only was it getting sufficient praise/recommendation but it appeared to be both not overly difficult to program but also because of its program nature had the ability to offer good download conditioning.

I had soon installed Inno Setup Compiler (v 5.2.3) and was beginning my education in its way of setting up the process of the Setup program through it's INI structure.

The numerous examples and those found online plus the help documentation allowed me to get started and soon I had created a Setup app that allowed for the checking and then (if required) the downloading/installing of .NET 3.5 framework.

Then I added to this the need to check for and install the following
  • SQL Server Compact Edition 3.5 SP1 (file: SSCERuntime-ENU-x86.msi)
  • Report Viewer 2008 SP1 (file: reportviewer.exe)
  • MS Office 2003 Primary Interop Assemblies (file: O2003PIA.MSI)
With these last three I couldn't figure out from the MS website whether they should be downloaded (which is stated by them and other people in relation to the .NET framework) and as such I have included them as files which are installed (again if certain Registry enteries are missing - the latter one I had to work out as I couldn't find it in my searches on the internet).

For a FREE piece of software and with what was available (examples and other peoples work plus the supporting documentation) the Inno Setup application is just perfect to allow me to get started 'delivering' my first proper application.

The ISS file.


Richard
Visionscape

Dr. Explain not capturing all fields - problem fixed

In the initial stages of using Dr. Explain I was 'blown away' by the way it itemised all the fields (with an exception of a few fields), I soon found myself finding that I was having problems with almost no fields being captured.

I realised that the screen captured before had little or no TextBox fields and this seemed to be the issue. After much playing around with the layout of the Windows Form to see if that was the issue I decided it was time to ask for help to see if there was something I could change in Dr. Explain or the layout of my application to fix the issue (I was certianly hoping it would be the former).

After submitting my issue to Dr. Explain I very soon (within 24hrs) had a reply from Dennis (Dr. Explain Team) asking if h could see the 'offending' application.

after a few days spent by me stripping the application down to just one of the 'offending' forms I emailed it off to Dennis (Friday) and (on my Sunday) received a reply with a solution to my issue.

"The easiest way to overcome the issue is to capture your GUI in Win32 mode. Simply unselect the third check box (Accessible objects) in 'Capture an object' dialog. So, all your editbox will be recognized."

And sure enough this resolved my issue.

It's always good to know that not only when you buy a product like this you are getting a very useful tool that helps simply and speed up a process that could be so terrible in the time and complexity, but that there are people (like Dennis) who offer such speedy and helpful support (thanks again Dennis).


Richard
Visionscape