Copy actual value or use RandomString generated before - Printable Version +- Micro Focus QTP (UFT) Forums (https://www.learnqtp.com/forums) +-- Forum: Micro Focus UFT (earlier known as QTP) (https://www.learnqtp.com/forums/Forum-Micro-Focus-UFT-earlier-known-as-QTP) +--- Forum: UFT / QTP Beginners (https://www.learnqtp.com/forums/Forum-UFT-QTP-Beginners) +--- Thread: Copy actual value or use RandomString generated before (/Thread-Copy-actual-value-or-use-RandomString-generated-before) |
Copy actual value or use RandomString generated before - mwietrzyk - 02-01-2012 Hi, I would appreciate help with copy action or re-use of RandomString in another action. I need to copy actual displayed value or use RandomString I generated before in another action. I have a code when I generate RandomString (see below) Action 1 Code: Str1=RandomString(15) Action 2 In action two I want to repeat the first script from action 1 (just use the same string I generated before) .Set Str1 does not help at all Any suggestions? Thx, Matt RE: Copy actual value or use RandomString generated before - basanth27 - 02-01-2012 You may want to read about environment variables. A transcript would be, In Action 1: Environment.Value("Str1") = RandomString(15) In Action 2: Msgbox Environment.Value("Str1") Or Learn about global variables. RE: Copy actual value or use RandomString generated before - mwietrzyk - 02-02-2012 Thx |