SIStester
13 years agoOccasional Contributor
Getting the currently focused item's name
Hello, I'd like to accelerate the creation of my tests by making a script to enter dynamicly text in a textbox. The only information I'm lacking is how to put the "current software.current form.currently selected textbox" in delphi.
I tried something like the following(that index variable is only an increment to have a different name every time I run the test):
procedure texte(nom);
begin
//Enters the text from the parameter in the currently selected text editor.
ActiveControl.SetText(nom+inttostr(Project.Variables.index) );
end;
seems like ActiveControl isn't recognized by Testcomplete. Is there another way to do that?
I tried something like the following(that index variable is only an increment to have a different name every time I run the test):
procedure texte(nom);
begin
//Enters the text from the parameter in the currently selected text editor.
ActiveControl.SetText(nom+inttostr(Project.Variables.index) );
end;
seems like ActiveControl isn't recognized by Testcomplete. Is there another way to do that?