FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour Function call
Posts: 1392
Joined: Mon May 14, 2007 09:49 AM
Function call
Posted: Sat Feb 04, 2023 04:10 PM
Hi,

There is a WebView object and an html text is loaded into it using the :setHtml method.
There is an aaa() function in this text.
Code (fw): Select all Collapse
 function aaa() {
     alert(12345) ;
  }
If I try to call this function :Eval('aaa()'), then nothing happens.

If I do so:
Code (fw): Select all Collapse
<button id='tst' style='display:none;'>Test function</button>

  document.getElementById('tst').onclick = aaa ;
  function aaa() {
     alert(12345) ;
  }
:Eval('document.getElement.ById("tst").click') - then the aaa() function is normally executed

Why can't I get a direct function call ?
Posts: 44162
Joined: Thu Oct 06, 2005 05:47 PM
Re: Function call
Posted: Mon Feb 06, 2023 07:40 AM

Please try using :Eval('alert( 12345 )')

regards, saludos

Antonio Linares
www.fivetechsoft.com

Continue the discussion