Forum Discussion
What RunOptions have you provided?
What version of TC are you using?
Assuming there's no other Chrome browsers running, this should work without issues,
function Test()
{
Browsers.Item(btChrome).Run("https://www.w3schools.com/howto/tryit.asp?filename=tryhow_html_file_upload_button");
var browser = Sys.Browser("chrome");
var page = browser.Page("*");
var button = page.FindElement("#iframeResult").FindElement("#myFile");
Sys.HighlightObject(button);
var submit = page.FindElement("#iframeResult").FindElement("//input[@type='submit']");
Sys.HighlightObject(submit);
Sys.Browser("chrome").Close();
}
It launches the website, and highlights the buttons, then closes the Chrome browser.
Hi rraghvani
In my RunOptions line, I only provided the URL of the website I want to access.
Regarding my TestComplete version, I'm currently on 15.61.48.7.
- rraghvani8 months agoChampion Level 3
I've edited my response. Have a look at the code example I've attached.
- AMR0138 months agoContributor
Thanks for the response. I modified my script to highlight buttons as you did with yours and out of my 5 attempts, the first four attempts highlighted the buttons of my desired objects successfully while the last attempt didn't do anything (Did what I outlined in my initial post).
In your modified response, you mentioned it should work without issues as long as there weren't any other Chrome instances running. I decided to check my Task Manager and with my problem run, I have one main instance of Chrome
I also checked TestComplete and there are a couple of Chrome Host instances showing as well.
- rraghvani8 months agoChampion Level 3
That's normal of Chrome.
Are you performing your tests against a 32-bit machine? I ask, because your Chrome is showing 32-bit.
Ensure you have the latest SmartBear Test Extension, I think it should be v15.0.4
Related Content
- 10 months ago
- 5 years ago
Recent Discussions
- 4 hours ago
- 20 hours ago