text========"everyone delphi fans"

i need help on delphi how to count the number of character enter by a user for exmaple if a user enters 2 in editbox1 and enters 5 in editbox2 then the program should display this using the above text in a memo.

"very"

meaning that the number specify in text 1 is is the beginning and the number specify in text 2 marks the ending.

please guys am new here help meeeeeeeeeeeeeeeeeeeeeeee

Hook keyboard keypress event, increase a counter everytime a key is pressed, I think that would do the trick

Thanks

text========"everyone delphi fans"

i need help on delphi how to count the number of character enter by a user for exmaple if a user enters 2 in editbox1 and enters 5 in editbox2 then the program should display this using the above text in a memo.

"very"

meaning that the number specify in text 1 is is the beginning and the number specify in text 2 marks the ending.

please guys am new here help meeeeeeeeeeeeeeeeeeeeeeee

ok - add an OnChange event - and make both text boxes point to this event handler

const
stSOURCE :string = "everyone delphi fans";

Procedure Text1OnChange(sender)
var inStart, inEnd :integer;
stOutput:string;
begin
inStart:= StrToInt(text1.text);
inEnd:= StrToInt(text2.text);
//should check values here....ie must be numbers, etc
stOutput:=copy(stSource, inStart,inEnd);
//put output somewhere
label1.caption:=stOutput;
end;

This article has been dead for over six months. Start a new discussion instead.