Hello,
I tried to use the Wptools APIs in a DLL Form project and the error: Acess Violation appears. At first, the wprichtext editor usually appears in a form inside the DLL, with the possibility of editing text. However, when using any text inclusion or formatting APIs the Wprichtext Editor has the error message "Acess Violation" and this message is repeated repeatedly when clicking on the editor. It is as if he can no longer focus on the sprichtext editor! If I don't use the APIs in WprichText the editor works correctly!
I used, for example, the APIs of a demo program. The CreateDemoText unit. Specifically the following procedure:
procedure CreateDemoText (RTFMemo: TWPCustomRtfEdit; Mode: TWPCreateDemoText);
The error points to an Assembler code for the Unit System method: class function TObject.InitInstance (Instance: Pointer): TObject;
...
$ ELSE! PUREPASCAL}
asm
PUSH EBX
PUSH ESI
PUSH EDI
MOV EBX, EAX
MOV EDI, EDX
STOSD <-------- the error happens here
MOV ECX, [EBX] .vmtInstanceSize
XOR EAX, EAX
...
Exception class $C0000005 with message 'access violation at 0x08e08593: write of address 0x00000000'. Process testeComposerDLLDelphiTokyo.exe (73788)
How could I solve this problem, since the DLL Form project is very important for my system architecture?