InstallShield 2009 Pre install - installshield

Is there any option to copy some of the files (pre installation) to the system before onFirstUIBefore() method. These files are also part of installer.
I am using install shield 2009 and project type is installer script.
EDIT:
Some more info. we need to run one utility which is part of setup.exe package. It should be run first in the OnFirstUIMethod() before showing up other dialogs to the user. There are around 5 dialogs in OnFirstUIMethod() method. The utility has some complex code and it's functionality can't be done with installer scripts (that's why this utility). My requirement is this utility should be part of installer package. Any thoughts are welcome.

If you add filed to the Support Files/Billboards section of the project, you can reference them in your project and specifically in OnBegin.
For example, if you have a file called foo.exe that you needed to execute, you could add it to the project as a Support File and the reference it using the SUPPORTDIR keyword. It would look something like this:
LaunchAppAndWait(SUPPORTDIR ^ foo.exe);

The OnBegin event is the first place you can do custom things in an InstallScript project, like copy files.

Related

Extend Visual Studio functionality for Installshield ISPROJ Project type

InstallShield must be the crappiest "industry standard" application in existence, for reasons too numerous to enumerate here. However, one of those deficiencies is something I'd like to be able to fix, and with my first foray into writing an extension for Visual Studio (currently using 2015 version).
InstallShield has created a .isproj type, to allow integration with Visual Studio. This allows a developer to create an installer that references the output of a project as the files to include in the installer (rather than having to manually select individual files to include). This works well enough as long as the .isproj is being built in Visual Studio, and in a solution that references the project for which you need the output.
However, I also have an automated build for my installer projects, that we run on a build server using MSBuild. When attempting to build this way, we were getting completely opaque error messages indicating that the project output references above couldn't be resolved.
As with all InstallShield errors, Googling for answers turned up nothing except for multitudes of other people having the same problem. So I decided to dig into the plain text of the .isproj to see what I could find.
As it turns out, the .isproj type is a just a regular MSBuild script, and it even has lines commented out that explain options that can be added to the project; one of those things that can be added is an ItemGroup containing ProjectReference nodes. Manually adding the nodes helped solve the problem. Command-line build now works.
However, I am dissatisfied with a) having to manually type this stuff in, b) having no visual representation of what projects are being referenced, and c) not finding out about a problem until the build fails. So, I would like to be able to extend Visual Studio to help me with this. Here's what I'd like to do:
1) Add a "References" node to the project in Solution Explorer that acts like the References node for any normal .csproj.
2) Restrict the available References to other projects in the the current solution.
3) Visually represent a project with missing references (e.g. by underlining the project name with a colored squiggly, as with errors/warnings), and potentially failing the build if missing (depending on whether I want to treat it as an error or a warning; TBD).
To these ends, I've downloaded MPF for Projects - Visual Studio 2013, which provides an SDK for creating a new project type.
However, before digging too deeply, I need to know if it's even possible to EXTEND an existing project type, as described above, as I obviously don't have InstallShield source code. Also, any links or guidance as to a starting point for doing so would be greatly appreciated.

Install just TortoiseMerge software and context menu items

I really love the TortoiseSvn diff software. I can download them standalone as a zip, but I really love when iI can select two files and then right click and from context menu click on "diff in tortoise". Is there any way I can install just this tool? I don't want the whole SVN suite.
http://tortoisesvn.net/downloads.html
Here is standalone TortoiseMerge: http://tortoisesvn.net/TortoiseMerge.html
You can't, sorry. Yes, you can!
According to this forum thread (from June, 2011, so pretty much over three years old), written by Stefan Küng, an author of TortoiseSVN, starting from version 1.7 of TSVN, TortoiseMerge does not ship as standalone.
You can go to Tools folder on TortoiseSVN's site at SF and get TortoiseDiff-1.6.7.zip file from there. It still quite outdated (see above notice), but certainly it is a standalone version of TortoiseMerge.
I needed something similar (just a standalone app to make diff files) and was able to copy the following out of the Tortoise install directory (C:\Program Files\TortoiseSVN\bin\) to make TortoiseMerge work on its own (similar to the accepted answer's suggestion). Maybe extract them from the full installer if you don't have it installed already?
TortoiseMerge.exe
libsvn_tsvn.dll
libapr_tsvn.dll
libaprutil_tsvn.dll
vcruntime140.dll
intl3_tsvn.dll
libsasl.dll
mfc140u.dll
msvcp140.dll
As far as the context-menu entry:
How add context menu item to Windows Explorer for folders and probably needing multiple "%" placeholders (e.g. myprogrampath\path\path\executable.exe %1 %2)
https://www.howtogeek.com/howto/windows-vista/add-any-application-to-the-desktop-right-click-menu-in-vista/
Instead of context menu items, a good workaround is to put it in the SendTo folder

Silent Installer with custom selection

Currently my installer is need user to choose which type of setting they want to use when install. Lets say got setting A,B and C.
If want to make this in silent installer. Is there any method can use?
I'm using install shield.
You can set PUBLIC PROPERTIES inside the MSI file from the msiexec.exe command line like this:
msiexec /i test.msi /qn TESTPROPERTY=1
These properties are the ones you have hooked up to values input in the GUI. They are now set by the command line (or defaults are used from the Property table) and the entire GUI section of the MSI gets skipped on install.
Here is a sample showing how INSTALLDIR is hooked up to the GUI (Wise for Windows Installer shown, same concept in Installshield and other MSI tools):
To play around with complex command lines for msiexec.exe I always recommend this nifty tool from Altiris: http://www2.wise.com/filelib/WICLB.exe - broken link, resurrected from Wayback Machine, seeing as the tool was freeware I assume that is legal - (see a screenshot of it here: installation using msi.exec open help options every time). Please run the download by virustotal.com for safety.

chef how to overwrite attribtues in json file

I'm trying to run the same recipe twice with different attributes.
Is there a way to specify it in the run list?
Example:
"myRecipe":{
"run-list": "recipe[test], recipe[test]"
}
and the first one should have flag=false while second one should execute with flag=true.
No, that's not possible. You have to implement such logic in your recipe and e.g iterate over an array.
I answered a similar question previously:
The short version is, you need to modify your thinking. If you need to install software and configure it, you might do better to think about breaking it apart into two pieces.
Longer answer: have you taken a look at any of the cookbooks on the opscode community site? Many patterns recur and work that others have published could certainly be useful... Especially as you appear to be just starting out with chef.
I've also tried using resources:
define :installx, :cmd=>'good', :upgrade=>true do
Chef::Log.info('cmd = #{params[:cmd]}')
if params[:upgrade]
Chef::Log.info('upgrading...')
else
Chef::Log.info('installing...')
end
end
installx resource
installx "name" do
cmd "install 1"
upgrade true
end
and it errors out: "ERROR: Cannot find a resource for define"
This is pretty much right out of the official documentation. If anyone know what's causing this, please let me know.
Some of the Chef cookbook are written very well in my opinion such as the visualstudio cookbook from https://github.com/daptiv/visualstudio.
I do have a case when I need to run this recipe twice. I have to install Visual Studio 2012 and 2013 on a machine to compile different source code. These versions of Visual Studio have the exact same silent install process by point to an XML file so it was easy to make it work for 2012 and 2013.
I was able to create a Chef role file to override the attributes of the visualstudio cookbook to point my private Visual Studio 2012 ISO. That was easy. Then I created another Chef role file for installing 2013 to point to a separate Visual Studio 2013 ISO. Since Chef doesn't run the recipe twice it ends up only installing Visual Studio 2013. :(
It would suck if I have to make two local copies of the "visualstudio" cookbook.

How do I backup my C++ Builder component installation?

I finally have my C++ Builder 2010 installation the way I want it, with all my components upgraded and installed. (touch wood)
I have been working with C++builder since version 1 and I know from countless previous traumatic experiences that this state of affairs could change in an instant. I would like to backup the installation and component set.
Is there a way to do this? A tool perhaps? A menu command that I have maybe missed all these years? I don't want to have to reinstall all the components from the bpl source again.
I make nightly backup images of my entire drive, I would like to do this for c++builder only if possible.
If it's a matter of simply copying files, which files would I need to copy? Are there entries in the registry that would need to be restored?
Thanks in advance for any thoughts and suggestions
The HKCU\Software\CodeGear\BDS\7.0\ registry section contains the "known packages" subtree that contains which components you have installed. reg export/import should save you some trouble.
You'll also want to backup/restore the actual files referenced there as well.
It has been a while since I used C++ Builder, but I will make two suggestions...
1) run regedit and looks for "builder". You will probably find a hive like hk_local_machine/software/codegear or such. Export that and you can import it later
2) have a look at GExperts - is they don't have the exact solution, they still have some pretty useful (and free) tools

Resources