views:

108

answers:

2

I'm currently creating an installer using INNO and I'm no pascal expert. Is there any way to use a TList object from within Inno, all I get is an "Unknown Type" error on compile.

+4  A: 

TList is not on the list of support classes. You can use an array or a TStringList instead.

If you really must have TList, then I suppose you could download the Inno Setup source code and amend it so it also registers TList with the scripting engine.

Rob Kennedy
Or shell out to a DLL written in Delphi so he has TList capability!
Robert Frank
Shell out? The shell has nothing to do with it, @Robert. But if you'd like to describe what you really meant in an answer, I'd vote for it.
Rob Kennedy
+3  A: 

Chris,

You could write a DLL in Delphi and then call it from the Inno script. (Search INNO help for "DLL". There are also examples of how to do this in the Examples subdirectory of your Inno Setup directory. See the CodeDll.iss" file.)

Or, could use Inno's ability to run other programs to run a Delphi program that uses TList. This can be done in Inno's [Run] section or using Inno's ShellExec function in your Inno Pascal code.

Robert Frank
Thanks for that frank, the only reason I accepted the other answer is simply because it was easier (in this case) to use another construct.
Chris Meek