problem with file "save as dialog box" - 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: problem with file "save as dialog box" (/Thread-problem-with-file-save-as-dialog-box) |
problem with file "save as dialog box" - caze - 12-09-2009 hi all , i am automating a web application . The web application has a test case to download different version of a file by clicking on download button. following is the record using QTP ------------------------------Cut from original code---------------------- Code: Dialog("0% of 15_pkgId129170115_2.5.4.").Dialog("File Download").WinButton("Save").Click this cod is for downloading a file called ""15_pkgId129170115_2.5.4"" as you can see from code now the problem is :if the file name changes from 15_pkgId129170115_2.5.4 to some "xyz" QTP displayed an error "The "0% of XYZ." Dialog object was not found in the Object Repository. which is quite genuine. now i want to script it in such a way that even if file name changes to xyz it should work without any error. I tried with following but failed: ---------------------------try 1------------------------------------ Code: Dialog(*).Dialog("File Download").WinButton("Save").Click --------------------------try2--------------------------------------- Code: Dialog("File Download").WinButton("Save").Click RE: problem with file "save as dialog box" - caze - 12-09-2009 hi guys , i tried one more thing enabling the smart object identification property of the dialog box. but its disabled by default . i cant enable it RE: problem with file "save as dialog box" - Saket - 12-10-2009 In your repository change the text '0% of 15_pkgId129170115_2.5.4' of Dialog("0% of 15_pkgId129170115_2.5.4.") object to '.* of .*' RE: problem with file "save as dialog box" - caze - 12-10-2009 hi @saket, thanks a lot . its working |