How to Prompt to enter id then execute the testcase

Class library usage, coding and language questions.
omayer
Posts: 458
Joined: Thu Oct 28, 2010 6:14 pm

How to Prompt to enter id then execute the testcase

Post by omayer » Mon May 07, 2012 9:30 pm

user code moduel -- Test exceution > how to prompt to enter "user id" then send id as parameter to execute an individual test case
Thank you ,
Beginner
Tipu

User avatar
Ciege
Posts: 1336
Joined: Thu Oct 16, 2008 6:46 pm
Location: Arizona, USA

Re: How to Prompt to enter id then execute the testcase

Post by Ciege » Mon May 07, 2012 10:07 pm

You can create your own form and get the data that the user puts into a textbox...
You can read from the console...
If this or any response has helped you, please reply to the thread stating that it worked so other people with a similar issue will know how you fixed your issue!

Ciege...

omayer
Posts: 458
Joined: Thu Oct 28, 2010 6:14 pm

Re: How to Prompt to enter id then execute the testcase

Post by omayer » Wed May 09, 2012 9:46 pm

Thank you Ciege, this code works for me -

Console.BackgroundColor = ConsoleColor.Green;
Console.ForegroundColor = ConsoleColor.Blue;

Console.WriteLine("Type Run Id:");
string input = Console.ReadLine(); // Read string from console

// Reset the color.
Console.ResetColor();

runControlTable.ReadRnControlTable(input);
Tipu