Forum Discussion

Largent803's avatar
3 years ago

Questions about not hard coding Login Credentials in TestComplete

I am working on some other questions that I have regarding the TestComplete during my evaluation process of the product.


Is there an easy way to create a test script so that the user credentials are not hard coded into the scripts.


textboxUsername SetText "XXXX" Sets the text 'XXXX' in the 'textboxUsername' text editor.
textboxUsername Keys "[Tab]" Enters '[Tab]' in the 'textboxUsername' object.
passwordboxPassword SetText Project.Variables.Password1 Sets the text Project.Variables.Password1 in the 'passwordboxPassword' text editor.
passwordboxPassword SetText Project.Variables.Password2 Sets the text Project.Variables.Password2 in the 'passwordboxPassword' text editor.
passwordboxPassword Keys "[Enter]" Enters '[Enter]' in the 'passwordboxPassword' object.


Now the way the system sets it up is that its hardcoded with a user name and their password.

I want to be able to generate a test where I can setup the code so that the other members on our team will enter their credentials to continue on with

a test?

7 Replies

    • Largent803's avatar

      I am not sure I am following this example that was given in the instructions. I am not creating a database I have an environment that references

      the table once the user credentials already entered. 

      So I could be the person entering my credentials including user name and password the system automatically references my privilege's 

      and then I want to create the test so that the individual who is using this test can enter their credentials and then continue on with the test. So basically

      it could be anyone on our team who is using these tests.

      • AlexKaras's avatar
        Champion Level 3



        If I got your question right...

        If you want to get password that is used when you are logging-in into your computer (i.e. your local system or domain password) then I am far not sure that this is possible at all.