[Rd] Rgui.exe 4.2.0 does not receive characters via the Windows API's PostMessage function
murdoch@dunc@n @end|ng |rom gm@||@com
Thu May 5 18:17:53 CEST 2022
On 05/05/2022 11:17 a.m., jcfaria wrote:
> Rgui.exe 4.2.0 does not receive characters via the Windows API's
> PostMessage function.
> The Tinn-R project sends messages to Rgui.exe (SDI mode) via the Windows
> API's PostMessage function.
> A simplification of the code (in object Pascal) can be seen below.
> procedure TfMain.btnPasteClick(Sender: TObject);
> i: integer;
> sTmp: WideString;
> hBN: HWND;
> hBN:= FindWindowA(nil,
> 'R Console (64-bit)');
> sTmp:= 'sd';
> for i:= 1 to Length(sTmp) do begin
> VK_RETURN, 0);
> This code has always worked fine for all versions of Rgui.exe with the
> exception of the last one released, ie 4.2.0.
> We've been trying to get around the problem on the Object Pascal side,
> but without success so far.
> Does anyone connected to the compilation of Rqui.exe know what the
> problem is?
It could be that the new build enforces Windows security more
stringently. More details are described in the answer to this question:
https://stackoverflow.com/a/40139498/2554330, but at a minimum you
should be checking the return value from PostMessage.
> Jose Claudio Faria
> joseclaudio.faria at gmail.com
> 55(73)3680.5545 - UESC
> 55(73)99966.9100 - VIVO
> If you have software to deal with statistics, you have arms,
> if you have good software, you have arms and legs,
> if you have software like R, you have arms, legs and wings...
> the height of your flight depends only on you.
> [[alternative HTML version deleted]]
> R-devel using r-project.org mailing list
More information about the R-devel