Close Popup_Editor

Close Popup_Editor

  

Hello, 

I'm trying to close a popup when clicking outside, but I can't. Someone knows a way to do this with Javascript? 


Note: I'm using Outsystems 8.


Thanks 

Hi Pedro

You can try this in the Javascript window.

$(document).ready(function(){
    $(body).click(function(){
      $(.YOUR_ELEMENT).close();
    });
});


Hope this help

Benji wrote:

Hi Pedro

You can try this in the Javascript window.

$(document).ready(function(){
    $(body).click(function(){
      $(.YOUR_ELEMENT).close();
    });
});


Hope this help

Hi Benji,

I already tried it but it didn't work.


Thanks for the suggestion.


Hello Pedro, 

Its working for me. I have attached the OML(My Service Studio Version : 10.0.609 ).

Add an expression and set "Escape Content" value to "No" 

Set the value of the expression given in below code Snippet.

"<script>

$('body').click(function(){
  RichWidgets_Popup_Editor_Close();
});

</script>"
Solution

Sekar Perumal wrote:

Hello Pedro, 

Its working for me. I have attached the OML(My Service Studio Version : 10.0.609 ).

Add an expression and set "Escape Content" value to "No" 

Set the value of the expression given in below code Snippet.

"<script>

$('body').click(function(){
  RichWidgets_Popup_Editor_Close();
});

</script>"

Hi Sekar,

It worked! 


Thanks.


Solution