Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

e.message string is not transfered to onTexTranslatedErrorProc #7

Open
jrathlev opened this issue Aug 14, 2023 · 0 comments
Open

e.message string is not transfered to onTexTranslatedErrorProc #7

jrathlev opened this issue Aug 14, 2023 · 0 comments
Assignees

Comments

@jrathlev
Copy link

In the except section of DeepLTranslateTextASync the parameter e.message is not transfered to the callback function onTexTranslatedErrorProc.
Whether this is only the case in Delphi 10 Seattle or also in other versions, I cannot say.

This code works in any case:

var
  se : string;
begin
     ...
      except
        on e: exception do begin
          se:=e.Message;
          if assigned(onTexTranslatedErrorProc) then
            tthread.queue(nil,
              procedure
              begin
                onTexTranslatedErrorProc(text, source_lang, target_lang,se);
              end);
        end;
@DeveloppeurPascal DeveloppeurPascal self-assigned this Aug 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants