Trigger button using javascript
Application Type
Traditional Web

Hi,

 i want to trigger a button which is invisble and from another button using a run javascript in traditional web application

thanks in advance.


buttonscript.oml

Hi,

Please do the below changes -

1. Set Visible = True for the OK Button.

2. Apply Extended properties - style = "display: none;"

3. Execute below javascript on Submit action -


"document.getElementById('"+Ok.Id+"').click();"


Please find the attached oml as well.

buttonscript.oml

Thanks for your help it worked šŸ‘šŸ»

Champion

Hi,

Oops, I am late to reply!

Anyways :)

  • Set the style as display:none with extended properties
  • Add an extended property to the button you set as Visible [ Jquery Approach] :
    • Property-name : onclick
    • Property-Value : "$('#"+yourHiddenButtonName.Id+"')[0].click();"

Hope it helps,

Assif

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.