bokkie wrote:2. After the build, I took a look in the Release -> Uncompressed -> data -> OFFLINE folder. There is only one folder DesignTime_NetBridge.dll and it's empty.
This seems to suggest to me there is something missing?
Yes there is something missing. But the files your are looking for will not be copied by the net bridge. you must do this yourself in your compile time net assembly.
especialy, the runtime net bridge dll and its ini file.
IA help - Design Time Exports wrote:
The functions which must be exported by the design time DLL and their expected behavior is described below.
CompileTimeBuild
This function is called when the project is being compiled. The function should copy the necessary files for its operation, modify the Windows Installer database if necessary, and indicate whether it will require access to setup files during installation.
(...)
BuildPath
The full path to the folder where the plug-in must copy its build files to. At a minimum, the plug-in should copy its Run-Time DLL to this build location. The plug-in may also copy other files as needed (for instance, if the plug-in installs any files, it should also copy those files).
You need to copy at least 3 files:
1. runtime net bridge dll
2. runtime net bridge ini file
3. your net assembly
Francesco Toscano wrote:In C++during Project build time the IDE plugin DLL is called by the function "CompileTimeBuild". With this function the IDE plugin is responsable to perform all the required file copy operations. So the plugin must physically copy all the required runtime dlls by to the directory pointed by the "BuildPath" paramenter of the function.
The same is true for the net assembly plug-in. it is not done automaticaly by the compile time bridge dll.
bokkie wrote:I tried adding the bridge dlls, ini files, etc (see screenshot) but nothing changed.
I'm still left with an empty folder in the Release build. I've tried copying foldes containing the files into the "right" place but it doesn't change anything. A little later, I'll 7z what I'm working with and I'll post it here for someone else to eyeball. It's really frustrating!
It brings me back to Francesco's comment about having to copy files in the CompileTimeBuild method. Has anyone actually done that? Right now, I'm relying on creating the folders myself after I've produced the output media but is that actually the right thing to do? I mean, I'm doing something after the build that IA didn't know about beforehand.
You must do it in your net assembly code. I'm not sure if it will work if you add the net bridge somewhere else. IA might not be able to find it afterwards, as it is not present in the expected directory.
glenharvy wrote:As far as I can decipher, there is no sample IDE Plug-in written in C# that includes the file copying function mentioned.
You are correct.
I wrote delphi for net samples, and a C# runtime sample.
The delphi samples were there to show that it is working, the C# sample was there to show that the progress callback can be called out of the net assembly in C# as well.
But the samples were not written with end users in mind. Not as a kind of a tutorial. All this was targeted at experienced developers, at my customer at IA. I see that this is causing some missunderstandings.
bokkie wrote:Good morning, Pawel. Thank you for looking at this thread and the problems some of us are having. If you scroll up a few replies you'll see a zip file I attached. If you have VS available would you be able to download my example and see if there is anything obviously wrong with what I have tried?
At first, sory for my late joining. But I'm not watching this forum. I just subscribed to some of the topics and am looking inside only if I got an emali notification.
christ23 wrote:But, my plugin - first only running in IAs debug-mode and later being called by "normal duble-click starting the .msi, but the throwing the "is not a valid integer value (see my other post) is still crashing. Seems i am just ONE step away from getting the plugin working.
Francesco and I have found an issue and fixed it. More about below, Please try it out and drop me an email if you still have problems.
One problem I found using C# is, that the fetch parameter was not send properly back.
I think this is a com think as the net bridge uses it to gein access to the net stuff.
With my delphi for net plugin it worked fine. To make it work with C# as well we will have to change the declaration of the function a bit, it should look now like this:
Code: Select all
public bool CompileTimeBuild(Int32 MSIHandle, string State, string BuildPath, bool Build, ref string Fetch)
then use just "true" or "1" for the true value. Case insensitive. any other value will be handled as false.
When using the net bridge, you always need to set it to true.
There was also a problem with the status text in the compile time C# code.
Code: Select all
- string TEST_STRING = "InstallAware\n2012";
That string is used in the code to set the new state parameter, as:
Code: Select all
//set the TEST_STRING in the buffer
NewState = TEST_STRING;
Francesco Toscano wrote:The carriage return char '\n' can't be used with plugin parameters.
For that there is an appropriate VARIABLE with IA called "NEWLINE".
This causes a serius error with IA engine that have as conseguence, that the BRIDGE EXE DLL is not correctly loaded by IA ( ...with the error "Plugin library not found".)
Francesco is testing and reviewing the fix. I send him my C# samples as well. As soon as he confirms that anything is fine now, he will upload the new dlls and the samples. Maybe a tutorial, Francesco
?
glenharvy wrote:Ok, hopefully that fixes the background processing but just as importantly (at least to me) is the IA Graphic User Interface. So far there doesn't seem to be one although I suspect the original requester of this excellent plug-in has designed one. I say requester because the plug-in itself doesn't seem to come with it's own IA GUI.
The Run DLL Plug-in supplied by IA is an excellent example and I am wondering if it is supposed to be the actual method of interfacing with the C# Bridge.
Presumably we will insert the path to the dll as referencing the bridge.dll and the bridge.dll in turn requests the c#.dll.
The net bridge is only a bridge between IA and its C# compile time and runtime plugins.
It is only an extension of the IA plug-in architecture, allowing for C# plug-ins.
It is not a bridge between IA and any C# dll.
Keeping that in mind, unfortunately, you are the one to write the GUI part for your plug-in.
ps.: I see my forum subscription is not working... I got no info about any replies... strange... I will look from time if there are new posts, but in any case, drop me an email if something is going on.