PDA

View Full Version : Add component .KeyPath error with InstallShield Pro 11



xajvaj
06-13-2005, 02:50 PM
This Visual Basic code worked in InstallShield Professional 10.5 but does not work in version 11. :mad: Did anyone experience the same problem?

With objNewComponent
Set filFkey = .AddFile(strFilePath & "\" & strFilename)
.KeyPathType = kptFile
.KeyPath = filFkey.Name <-------*** Line with problem! ***
.Permanent = blnPermanent
.SharedDLLRefCount = False

--------------------
strFilePath = "C:\MyFiles"
strFilename = "ACTBOLI.exe"
filFkey.Name = "actboli.exe"

If I hardcode assignment statement:
.KeyPath = strFilename
then it works fine.

I did notice that filFkey.Name shows everything to lowercase with "_" for spaces. Don't know why it's an issue since it worked in 10.5. IS this a bug with version 11?

Error I get:
---------------------------------------------
Item not found
>ISWiAutomation.ISWiFiles.Item
>ISWiAutomation.ISWiComponent.KeyPath

xajvaj
06-21-2005, 02:30 PM
I found another post that is exactly the problem that I am having.

It seems like the problem was fixed at some point and probably re-introduced with version 11. Installshield developers probably overwrote their code.

http://forum.installsite.net/index.php?showtopic=10525

I upgraded to version 11 since I had problems building .NET MSIs with version 10.5 - "Error -6213 due to .NET dependencies..." But seems version 11 solved one problem but introduced another.

I have a support request opened with InstallShield but its been a week and nothing has come of it yet.

Anyone else having the same problem with InstallShield Pro 11 ???