When calling: pTextServices->TxSendMessage( EM_STREAMIN, ( WPARAM ) SF_RTF, ( LPARAM ) &editStream, &lResult )
editSteam.EditStreamInCallback is not being called, but if SF_TEXT is used instead of SF_RTF, then editSteam.EditStreamInCallback gets called.
According to MS docs: https://learn.microsoft.com/en-us/windows/win32/api/richedit/nc-richedit-editstreamcallback
An error occurs that prevents the rich edit control from transferring data into or out of itself. Examples are out-of-memory situations, failure of a system function, or an invalid character in the read buffer.
In these cases editStream.dwError should contain a different value from zero, but it is zero.
This is the used RTF: "{\rtf1\ansi\pard test \par}" in the code escaped as:
"{\\rtf1\\ansi\\pard test \\par}"
Thank you
Fixed and working fine thanks to my friend Mr. Bruno Cantero (C3)