Cannot identify Object "Notepad" error - 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: VB Scripting/Descriptive Programming (https://www.learnqtp.com/forums/Forum-VB-Scripting-Descriptive-Programming) +--- Thread: Cannot identify Object "Notepad" error (/Thread-Cannot-identify-Object-Notepad-error) |
Cannot identify Object "Notepad" error - bostonma - 04-27-2010 Hi, I have a script where I'll have to read a value from the opened notepad, but I get error "Coonot Identify the Object "Notepad(of class window).Verify that this objects properties match an object currently displayed in your application. I tried to use Descriptive Programming for the notepad, that did not work as well. Strange thing is same exact code works with no issues on one machine but not on this one. Can someone please share their experience if they faced this issue or any ideas to resolve it?I appreciate any help! RE: Cannot identify Object "Notepad" error - manishbhalshankar - 04-28-2010 Hi Bostonma, Check this out: Code: Option Explicit RE: Cannot identify Object "Notepad" error - Saket - 04-28-2010 @Manish - I think the requirement in original query is bit different than the solution you provided for. I think bostanma wants it from an opened Notepad and getting error for Window object. (May be this is what Bostanma wants to do here, lets confirm it) also in the code 'wscript' object has not been initiated anywhere, you can not use the code in QTP. @Bostanma, - Manish has provided is an alternate way to read a text file, if this is not that what you are looking for, Please paste your lines of Code here, so that I can understand what actually you are trying to do. RE: Cannot identify Object "Notepad" error - manishbhalshankar - 04-28-2010 Yes Saket, Sorry I missed to change wscript.echo to msgbox and remove WScript.Quit() |