Guys, on Monday I worked ~ 4 hours to create my first CDR 2019 document with macros. An algorithm ensures, that the document is saved from time to time, those macros should process images from a folder and save the output in a new folder. After the last image had been created, my document with macros had been saved, and I finished my work.Today I want to use the macros again, opened my document, but there hadn't been any VBA code anymore. The last processed image had been saved with the document, but no VBA-Code is in.I also did a small test: I created a new document, wrote a small 'Hello World' Sub, where the document gets saved as well. I ran it, closed it and reopened it: No VBA anymore.If you want to use VBA, avoid Corel 2019!
Note that this issue has been addressed with Update 2 of CorelDRAW Graphics Suite 2019.
"VBA macros are preserved with the CorelDRAW (CDR) file upon saving."
While trying to workaround this bug I found another one:CorelDraw 2019 calls Document_Open() vba-handler two times.How to reproduce:
Create new .CDR-file with any previous CorelDraw version (for example with CorelDraw2018).
Then in its "ThisDocument" part write this VBA code:
Private Sub Document_Open() MsgBox "Document_Open()" End Sub
Save & close this document.In CorelDraw2019 options uncheck the "Delay VBA load" option.Open created document in CorelDraw2019 and click "Enable macros" button in "Security Warning" dialog.Expected: Message box with "Document_Open()" string appears once.Actual: Message box with "Document_Open()" string appears two times.