Error in Calling function Libraries - 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: Error in Calling function Libraries (/Thread-Error-in-Calling-function-Libraries) |
Error in Calling function Libraries - Anum Saleem - 02-23-2012 Using QTP 9.2 Windows 7 Im learning how to create and use functions libraries in QTP. I have created log in and log out functions for my application Code: Function login() Code: Function logout() I know these objects are not present in the OR, how can I used these Functions in my test? Need guidance for it. Thanks. RE: Error in Calling function Libraries - inborntester - 02-23-2012 you can get solutions on any of the below 1. Code these function as reusable actions and call actions 2. use Descriptive programming 3. add the objects in to Shared Repository and store externally say "C:\Repository.tsr". and add the below codes at the start of the functions Code: Dim qtApp RE: Error in Calling function Libraries - Anum Saleem - 02-23-2012 Adding the above code generating an error in Function library: Error in library file. Your function library may not be valid. RE: Error in Calling function Libraries - inborntester - 02-23-2012 i think code sensitive to QTP 9.X version. conclude you are using later. instead of old codes, add the object repository code at the start of the function like Code: RepositoriesCollection.Add "C:\sh.tsr" before that ensure all objects used in functions are added and stored in the shared object repository. (like C:\sh.tsr) and you can try other ways also. RE: Error in Calling function Libraries - rajpes - 02-25-2012 I guess you have not associated the function library with the test RE: Error in Calling function Libraries - Anum Saleem - 02-28-2012 I have associate function library with test |