Вниз
Скачать: CL | DM;

Помогите с Selection в Memo.   Найти похожие ветки 

 
Sagrer   (2003-11-04 19:37) [0]

В общем такой код

Procedure CheckSelection;
begin
//Проверялка селекта в меме текстофайла...
If MainF.TxtFileMemo.Focused = true then begin
If MainF.TxtFileMemo.SelLength > 0 then begin
If TextSelected = false then begin
TextSelected := true;
TextSelStart := MainF.TxtFileMemo.SelStart;
TextSelLength := Length(MainF.TxtFileMemo.Selection);
TextSelection := MainF.TxtFileMemo.Selection;
ApplyZapis;
end;
end
else begin
If TextSelected = true then begin
TextSelected := false;
ApplyZapis;
end;
end;
end;
end;

Вызывается это у меня OnMouseMove и OnKeyUp для Mamo.

Но Selection почемуто - всегда получается только первый символ из выделения... тоесть немогу получить длину выделенного текста :(...

Как мне ее узнать?


 
Спрашивающий_   (2003-11-05 04:35) [1]

procedure TForm1.Button2Click(Sender: TObject);
begin
Text:=IntToStr(Length(Memo1.SelText));
end;



Страницы: 1 вся ветка

Скачать: CL | DM;



Память: 0.44 MB
Время: 0.034 c
6-41833
Urvin
2003-09-07 02:14
2003.11.13
Помогите научиться работать с сетями


3-40919
Hooch
2003-10-19 13:06
2003.11.13
SAP DB


14-41980
Brahman
2003-10-17 16:20
2003.11.13
Насчет 17-й строки


3-40794
Vemer
2003-10-19 19:34
2003.11.13
Inner Join в Interbase


3-40832
chtr
2003-10-22 07:16
2003.11.13
Как ускорить запрос в Access




   Наверх