I include version information in my Delphi plugin .dll, but this information does not show up when looking at it in Explorer like it does for normal .exes/dlls. Is there a way to do this?
If not, how can I retrieve the plugin major and minor version, either from the .NET host automatically or from within the plugin?
//THYModuleManager.PluginDescriptors holds a list of all plugin descriptors that available to module manager
//By using plugin descriptor you can get information about plugin such as name, version, description, etc.
for I := 0 to ModuleManager.PluginDescriptorCount - 1 do begin
pl :=ModuleManager.PluginDescriptors[i];
// pl.MajorVersion
// pl.MinorVersion
end;
note: it retrieves only versions that are specified in plugin initialization:
You can set up these variables (myMajorVersion/myMinorVersion) from standard VS_VERSION_INFO struct in runtime.
see this solution how to receive file (product) versions.