Right now my .NET macro is built for 220.127.116.111, I found that if I load it into earlier version of CorelDRAW X7 it would outright crash the whole program.
Is there a way to check CorelDRAW DLL Assembly version so that it would prompt user to update their CorelDRAW? I'm thinking that I should do this within VBA before calling the DLL, but I haven't found out how.
In VBA this simple code returns Corel Version:
You can use it in a corel Event...
You can check that using a VBScript:
Set Cor = CreateObject("CorelDraw.Application")
MsgBox "Corel " & Cor.Version, , "Corel Version"
Set Cor = nothing
Or directly in C# using Corel COM object or not. Using it in a similar way of VBScript or extracting from Registry the Corel.exe path and than the version of VGCore.dll in Assembly folder. Relatively easy...
Spot on, thank you.
In C# Addon you can modify the Constructor in Main entry
public partial class DockerUI : UserControl
private Corel.Interop.VGCore.Application corelApp;
public DockerUI(dynamic app) //use reflection for support any corel version
//Show a friendly message
this.corelApp = app as Corel.Interop.VGCore.Application;//cast for correct type, reflection will showdown your app
protected bool versionOk(string version)
//Make your check
© Corel Corporation. The content herein is in the form of a personal web log ("Blog") or forum posting. As such, the views expressed in this site are those of the participants and do not necessarily reflect the views of Corel Corporation, or its affiliates and their respective officers, directors, employees and agents. Terms and Conditions / User Guidelines.