在memo1中通过的句子在richedit1中却卡了?
//下列代码在memo控件中正常发挥功能
procedure TForm1.RichEdit1MouseDown(Sender: TObject; Button: TMouseButton;
Shift: TShiftState; X, Y: Integer);
var
lc:Longint;
CharPos:Word;
begin
lc:= SendMessage(RichEdit1.handle,EM_CHARFROMPOS,0,x+(y shl 16));//向文本框传递消息EN_CHARFROMPOS
CharPos:=Word(lc);
end;
//'Access violation at address 74DA95B3 in module 'RICHED.dll.''
有解决办法吗?