joelau

Get value from custom javascript

Discussion created by joelau on Mar 8, 2018
Latest reply on Oct 11, 2018 by reiva13

Hi all, if i have a custom javascript which is call a web service and return a string "HelloWord", how can i display the string to the form label control? thanks.

 

function fun() 
{
   var data="hello";  
   $
.get("http://localhost/ws/service.asmx/HelloWord", function(response) {
            
data = response;  
      
}).error(function(){ 
      alert
("Sorry could not proceed");
      
});   
   return data;
}

Outcomes