How to use ExecuteFile() ?? - 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 Others (https://www.learnqtp.com/forums/Forum-UFT-QTP-Others) +--- Thread: How to use ExecuteFile() ?? (/Thread-How-to-use-ExecuteFile--2149) |
How to use ExecuteFile() ?? - Star - 07-30-2009 Hi, I need to import file. I m using ExecuteFile() for importing file, but i have an error on this function. May b i m not using it with right path. The scenario is that i created a script with named "Test2", in which i implemented functions, and i have to use those functions from this file. I have another script file named "Sequence", i have to use functions of script file "Test2" in "Sequence" script file of QTp. i m doing this: ExecuteFile ("D:\Test2.mtr") but it is giving error. I also tried the following all: Code: ExecuteFile ("D:\Test2\Action0\Resource.mtr") but all are giving errors. Please tell me, where i m wrong? Thanks RE: How to use ExecuteFile() ?? - KVK - 08-03-2009 Hi Why dont you write all ur function in a vbs file and load it in your tests. Executefile statement doesnot load .mtr or . mts files - Mr K RE: How to use ExecuteFile() ?? - Saket - 08-03-2009 Execute file statement is able to execute VBScript statements only. I dont think one can execute qtp test with this. RunAction can be used to include another test in one test. If you want to use the funstions in another test then you will have to put those functions in a library file then either you can associate this file in resources or you cna run through execute file. |