Re: Disable Code Caching (324 Views)
Occasional Contributor
Posts: 5
Registered: ‎03-26-2014
Message 1 of 4 (369 Views)

Disable Code Caching



We are developing code in notepad++ and running it from uft. However we're having issues with uft caching code. So whenever we make some changes to our code and save it, uft is still using the old cached code. We have to either restart uft or reopen the library in the uft code editor in order to recache it.


Is there any way to stop uft from caching the code, and instead always run the code in the files? Alternatively is there a way to force yft to always recache all code at the start of a run?

HP Expert
Posts: 517
Registered: ‎04-12-2012
Message 2 of 4 (324 Views)

Re: Disable Code Caching

Hello Eric,


   Try LoadFunctionLibrary in order to Load the libraries each time test run.


   At the begining of the test load all the libraries needed by code.

   LoadFunctionLibrary "c:/temp/library1.qfl" 

   LoadFunctionLibrary "c:/temp/library2.qfl" 

   LoadFunctionLibrary "c:/temp/librariesneeded.qfl" 




If you find that this or any post resolves your issue, mark it as an accepted solution.

Note: The Opinions expressed in my post are mine alone, and do not reflect the opinions of my employer. No warranties express or implied for any answered posted.

Occasional Visitor
Posts: 1
Registered: ‎09-11-2014
Message 3 of 4 (243 Views)

Re: Disable Code Caching



Unfortunately this doesn't help when libaries are loaded directly from Quality Center. UFT stores the files somewhere in a temp folder and reloads them from there, when the test is started. If I edit the library outsite of UFT (we're using Test Design Studio) and save it to QC, the file won't be downloaded again and my changes won't be visible until I manually reopen the file in UFT.


Additionally I couldn't debug a library loaded via LoadFunctionLibrary, breakpoints inside this lib were ignored. It only worked if I set a breakpoint before calling LoadFunctionLibrary and used Step-Into feature.

Occasional Visitor
Posts: 2
Registered: ‎09-22-2014
Message 4 of 4 (173 Views)

Re: Disable Code Caching



We're experiencing the same problem. We load some libraries with the LoadFunctionLibrary function. When we change code inside these files with notepad and re-run our tests, UFT runs the cached code instead.

The only way to fix it is to restart UFT.

The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.