3
Contributors
6
Replies
7
Views
10 Years
Discussion Span
Last Post by radu84
0

Hi,
I am new to delphi and I have a delphi designed dos point of sale program.
I need assistance to open the program for a small reward.
If you are interested I can mail you the executables and further instructions.

0

procedure TForm1.Button1Click(Sender: TObject);
begin
showmessage(inttostr(length(trim(edit1.Text))));
end;

0

thank you but this gives the total length of the text - if 'barbara' is entered and the character is 'a' - the result must be 3

your help appreciated

0

thank you but this gives the total length of the text - if 'barbara' is entered and the character is 'a' - the result must be 3

your help appreciated

this is very simple, i'll give you the answer but i'm not sure how much you'll learn.

counter:=0;
for i:=1 to length(s) do
if s=your_character then
inc(counter)

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.