cbool & eval - 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: cbool & eval (/Thread-cbool-eval) |
cbool & eval - Sivapratha - 02-15-2013 Hi, Can anyone explain the difference between cbool and eval func with example? Thanks in advance... RE: cbool & eval - newqtp - 02-15-2013 In vbscript x = y can be interpreted two ways. The first is as an assignment statement, where the value of y is assigned to x. The second interpretation is as an expression that tests if x and y have the same value. We use Eval method if x=y result is True; if they are not, the result is False. And CBool method test, if expression x=y evaluates to a nonzero value, returns True; otherwise, it returns False. Code: Dim A, B, Check , c, D |