dtf

Why is vbs able to find the INSTALLLOCATION when C# using both DTF and MSI API cannot?

让人想犯罪 __ 提交于 2020-08-10 03:38:39
问题 VBS works as I desired, but both COM API and DTF using C# is not locating the InstallLocation. Followings are what I have done so far. Thanks to this post, I was able to find a InstallLocation that is not available on registry using vbs. I understand that vbs is calling for COM API available on %WINDIR%\system32\msi.dll . C# COM API So I thought I would use C# to call this method up. But it failed. Even though I can confirm the existence and installation, it cannot open one of the product

How to extract and run a file during installation

心不动则不痛 提交于 2020-01-05 08:47:08
问题 I have created a Custom Action (DTF) with C#. In that CA, I would like to extract a file from the msi (declared as Binary in wix) and run it with some arguments. I haven't found any samples or help about that.. I have to execute a request on the msi, but I would like to have a sample. Thanks! 回答1: The DTF.chm has a sample how to update the Binary table. It's in "Working with MSI Databases" topic. And you can guess how to do the opposite operation. The code might look like this: using (var db

WiX custom action with DTF… quite confused

牧云@^-^@ 提交于 2019-12-12 10:25:00
问题 Okay, I have decided the only way I can do what I want to do with WiX (thanks to an old installer I didn't write that I now have to upgrade) is with some CUSTOM ACTIONS. Basically, I need to back up a file before the RemoveExistingProducts and restore that file again after RemoveExistingProducts. I think this is what's called a "type 2 custom action." The sequencing I think I understand, however, what I don't understand is first of all how I pass data to my C# action (the directory the file

WIX : Adding and Reading cabinet file to msi Installer programatically with DTF to allow dynamic customization of installers

久未见 提交于 2019-12-12 03:25:51
问题 We created our MSI Installer using WIX Toolset. and we need to customize the installer dynamically according to user specific files e.g Themes and Dialogues. We use this link to add Add Cabinet File to Installer but i can't read it. We want to know the best place to read the Cabinet file along with its files(customization files). Shall we do this in a custom action or what is the best place to do that? Also, we need a sample code that we can follow to achieve this task? note:- Our Cabinet

Adding cabinet file to msi programatically with DTF (wix)

混江龙づ霸主 提交于 2019-12-11 20:33:37
问题 Introduction to the Task at hand: can be skipped if impatient The company I work for is not a software company, but focus on mechanical and thermodynamic engineering problems. To help solve their system design challenges, they have developed a software for calculating the system impact of replacing individual components. The software is quite old, written in FORTRAN and has evolved over a period of 30 years, which means that we cannot quickly re-write it or update it. As you may imagine the

Can only read/write 21 chars to InstallShield property from VB.NET

我只是一个虾纸丫 提交于 2019-12-11 11:40:48
问题 I'm using VB.NET and a custom action from within InstallShield to update some properties during an install. Everything works as long as I don't try to read or write more than 21 characters into the property, in which case it crashes. Just to be clear, if I enter this string "123456789112345678921" into the property via IS, then try to read it from VB.NET, everything works. If I add another char and read that, it crashes. Writing is similar - if I write (from VB.NET) the first string above it

Accessing InstallShield “Support Files” from DTF (Managed Custom Action)

佐手、 提交于 2019-12-11 11:11:32
问题 I have a bunch of .SQL scripts placed in the "Support Files" view of InstallShield. I want to access those SQL scripts in my custom action (via DTF). How can I do that? 回答1: InstallShield has a custom action to extract support files, called ISSetupFilesExtract. I guess when you add a support file, this action is automatically scheduled by the InstallShield engine. Hence, you can schedule your DTF custom action after ISSetupFilesExtract and address the support files extracted to the temp

DTF and MsiGetProperty

南楼画角 提交于 2019-12-11 06:46:19
问题 Related to: Accessing InstallShield "Support Files" from DTF (Managed Custom Action) I need to read the property SUPPORTDIR . According to this forum (http://community.flexerasoftware.com/showthread.php?t=180742&page=3), I need to use MsiGetProperty. How can I call MsiGetProperty from DTF? 回答1: DTF's Session class has the method: public string this[string property] get: set: This gets remoted over to the unmanaged C++ side where they invoke MsiGetProperty and MsiSetProperty. It's kind of like

How do I encrypt app.config file sections during install with WiX?

余生长醉 提交于 2019-12-09 16:50:39
问题 I have found an example for encrypting a web.config during installation here, but my app is a windows service. The aspnetreg_iis method works only for web.config files. I know how to programatically encrypt the config file, but I don't think I can do that using WiX. Am I wrong? Any ideas? 回答1: Here is what I ended up with... I used WiX and DTF to created a managed code Custom Action to encrypt a given section of a config file: public static void EncryptConfig(Session session) { var configPath

Get feature installation cost prior to installation

泄露秘密 提交于 2019-12-08 18:11:24
We're making a custom boostrapper / external UI for our installation. We want to provide a "Custom Installation" dialog (like in MSI) to allow the user to choose feature(s) they want to install or remove. Currently, we are able to read the features (and other feature details like description) from the MSI database itself (by running an SQL query on the Feature table). However, we also want to display the cost of installing a feature. Windows Installer "Custom Installation" dialog is capable of doing this. I think we can mimic the behavior by doing the following: Pick a Feature that you want to