Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Trigger a button click using javascript

Explorer ,
Jul 02, 2016 Jul 02, 2016

This, I hope, is simple to do, but I'm just having trouble with the script. 

Assuming I have a button called "buttonA", and another called "buttonB":

I'd like the user to click buttonB, which would then cause buttonA to click. 

What is the javascript I should use in buttonB?

Thanks so much.

746
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jul 02, 2016 Jul 02, 2016

Is this a Captivate question? If yes, can you explain more in detail what you want? Clicking is an event linked to a user action, what do you mean that another button should be 'clicked' when a button is clicked by the user? What is the purpose for such a request?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Jul 03, 2016 Jul 03, 2016
LATEST

Hi Lilybiri.  It's mainly because I sometimes find that a javascript gets rejected ("incomplete") in advanced actions but works fine as a simple action, in the main properties panel. Maybe there are some errors in my coding that the simple action just ignores.

Down the road, not sure what other benefit it would serve.

But I'm even having trouble with this code on triggering advanced actions with javascript,

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Help resources