I would like to create a unit file with a number of functions and procedures in this unit (let's call it MyFuncs.PAS).
I would also like to create a package containing this unit (MyFuncs.PAS) which I would like to distribute as a runtime package.
Further more, I would like to:
1) dynamically load this runtime package from my main project
2) use the functions & procedures contained within the units in this runtime package from my main project
3) I would like to be able to change properties of components in my main EXE from function/procedures contained within this runtime package.
I know how to create a new package (I just included MyFuncs.PAS in the pakage file and told it to compile a runtime only package (BPL-file)).
I then switched the options for my project to compile with runtime packages and added this new package (MyPackage.bpl) to the list of runtime packages.
I've places a button on the main form of my app. This is it's OnClick event:
x := LoadPackage('MyPackage.dpl');
//TestFunc is a function in my MyPackage
The problem is that every time I try and compile my project I get "undeclared identifier TestFunc".