norgepaul / TChromeTabs

Comprehensive Delphi implementation of Chrome's tab system
Other
215 stars 78 forks source link

AccessViolation when loading from DLL #50

Closed ghost closed 7 years ago

ghost commented 8 years ago

When loading the control within a DLL there will be an access violation and the program crashes.

The problem is described here: https://steema.com/wp/blog/2014/03/12/teechart-and-gdi-inside-a-dll/

And the fix:

initialization StartupInput.DebugEventCallback := nil; StartupInput.SuppressBackgroundThread := False; StartupInput.SuppressExternalCodecs := False; StartupInput.GdiplusVersion := 1; GdiplusStartup(gdiplusToken, @StartupInput, nil);

norgepaul commented 7 years ago

Thanks for the info