ContributionsMost RecentMost LikesSolutionsRe: Permission Denied - when attempting to use Exists. Thanks Leandro. A modified version of this worked for me. The page elements do not refresh in the same order each time so I had to FindChildByXPath and test for null with a rather long xpath statement prior to being certain the necessary page components had loaded. In the event that anyone else runs in to this, here is the function I used. Perhaps there is a more elegant way to do this, but it seems to work. Thanks, Brent //xpathToFind = the xpath statement defining the items that need to be found only when the page is loaded, but not while updating function WaitForWindowToFullyLoad(pageToWaitFor, xpathToFind, timeout) { if(timeout == undefined) { timeout = 60000; } var stopTime = GetTickCount() + timeout; var found = pageToWaitFor.FindChildByXPath(xpathToFind); while (GetTickCount() < stopTime) { if(found == null) { aqUtils.Delay(500); found = pageToWaitFor.FindChildByXPath(xpathToFind); } else { break; } } return 1; } Re: Permission Denied - when attempting to use Exists. I've tried using .Wait and .WaitPage, but it's not working because the page is actually there already. Here is the timeline of the page as I understand it. 1- Page is available prior to any updates 2- I initiate the command which goes out to the DB to obtain the updated information. The page is still "there", just not updated because the DB is retrieving the information and the update hasn't started yet.During this stage .Wait finds the page because it's already there, just not fully updated. Since it finds the page, the next command in my script executes and crashes. 3-the page is loading/updating the HTML. During this stage I suspect that .Wait would work. 4- the page is fully loaded and updated again. I think the error occurs when I am trying to access the page between stage 3 and stage 4. If I use the.Wait by initiating it at the end of stage 2 it 'finds' the not updated page in stages 2/3 rather than waiting until stage 4 is done. I'm not seeing a way to initiate the .Wait later than stage 2 without some hacky aqUtils.Delay. thanks, Brent Permission Denied - when attempting to use Exists. I'm running in to an intermittent problem (10% of the time) where myControl.Exists is giving me a Microsoft JScript runtime error. I run in to in several places in my code, but one such example is where I'm attempting to wait for a control to become available, and when it does I click on it. Here is the code that is generating the problem. do { myControl = page.FindChildByXPath(xpath_element); } while (!myControl.Exists && elapsedTime <= maxWait); So far I've checked to ensure it's not related to my browser (since it happens in any browser), or my security level since I'm an admin on my machine and all the files I'm working with are local. I have a hypothesis on the cause, but it's just a stab in the dark. These seem to correlate to when the page is going out to the database to obtain updated records, then it updates the page. Could it be related to the fact that the DOM is changing while this method is running? PS I find the same problem when posting messages to the Log- also happens intermittently. I'd appreciate any thoughts on how to deal with this. Thanks! Brent SolvedRe: Using VB Script within JScript project Alex - as it turns out the problem is that the existing TC project has a dozen scripts in use that are in JScript so it looks like I'd either end up re-writing this particular one, or the rest of them. The underlying project I'm testing is actually written in OpenEdge Progress, which is providing a few interesting challenges itself. ChrisB- thanks for the link. Re: Using VB Script within JScript project Thanks Alex. I was starting to suspect that re-writing the script isthe only solution since an extension will not work for what I need to do. Appreciate your assistance. Using VB Script within JScript project I'm new to TC, so my apologies in advance if there is an obvious answer to this that I'm missing. I have an existing VB Script that I wish to call from within my JScript project. When using Add...Existing Item the project looks for a .sj file rather than a .sbv file. If I override this and add the .sbv file anyway, I'm not able to access the script it in the fashion that I would for an imported .sj script (USEUNIT) because the project is looking for a JScript file. I've tried creating a new project for just the VB Script within the same Suite, but I encounter the same problem referencing it because of the scripting language mismatch. I could re-write the VB Script if there are no other solutions, but the script is rather extensive and I'm hoping to save myself the time of re-writing. I'm hoping that someone has a suggestion on how I can approach this. Solved