We’re moving our forums to a new platform.

You can still browse and search existing topics, but you can no longer create new topics or post replies.

For questions, technical issues, or feature requests, please don’t hesitate to contact our support team at support@advancedinstaller.com.

Thank you for your understanding!

ktdeveloper
Posts: 1
Joined: Tue Oct 29, 2013 2:44 pm

Creating installer that copies files from source to target

I am new to software development (though not programming). I am in the process of delivering my first application for commercial release, and I am in need of a single-click installer package. I looked into a number of solutions - I coded my own in C# (it basically just grabs my three folders to their respective destinations), but ran into some issues with bundling some IO libraries. Since I am using Visual Studio Express 2012, I cannot use the InstallShield module. I found Advanced Installer, and would like to see if this service is suitable for my needs.

I have three folders:

1. myApplication2013 folder
2. myApplication2014 folder
3. System.Data.SQLite.dll

The logic of my C# code is the following:

Code: Select all

    public static void installer(){
            deleteLegacyFiles(); // deletes legacy myApplication directories and files
            moveSQLite(); // moves system.data.sqlite database to directory
            if(checkRevit2013()){ // install myApplication 2013 if Revit 2013 is installed
                moveMyApplication2013();
            }else if(checkRevit2014()){ // if Revit 2014 is installed, install myApplication 2014
                moveTally2014();
            }else{ // tell user both Revit 2014 and Revit 2013 is not installed
                System.out.println("It does not look like you have either Revit 2013 or Revit 2014 installed.");
            }
        }
The target locations per folder/file is the following

1. myApplication-2013 is:

Code: Select all

C:\\ProgramData\\Autodesk\\REVIT\\Addins\\2013
2. myApplication-2014 is:

Code: Select all

C:\\ProgramData\\Autodesk\\REVIT\\Addins\\2014
3. System.Data.SQLite.dll is:

Code: Select all

C:\\Windows\\Microsoft.NET\\assembly\\GAC_64
How do I specify, in Advanced Installer, to copy these directories from the source location (i.e. user specified - so when the user unzips, those three folders above could be on the desktop) to the above locations.

Note: This is a post-compilation installer, that is, this is not done within VS Express, but outside of it.

I am also interested in creating a merge module - but I guess this will need to be done pre-compilation? If I am wrong, please correct me. Does Advanced Installer do this?

Thank you!
Bogdan
Posts: 2796
Joined: Tue Jul 07, 2009 7:34 am
Contact: Website

Re: Creating installer that copies files from source to targ

Hi,

As replied over mail, yes, this can be done very easy with Advanced Installer. On the Check if folder exists & Install files on existing folder forums thread my colleague Dan explains how this can be done, he also included a sample project for you.

You can also create merge modules, but with the Enterprise edition of Advanced Installer.

Best regards,
Bogdan
Bogdan Mitrache - Advanced Installer Team
Follow us: Twitter - Facebook - YouTube

Return to “Building Installers”