I am trying to trigger "Enter" key event once whatsapp window is opened so that message is automatically sent. Any ideas how this can be achieved?
The script below successfully opens the window within the application on button click.
var messageURL= 'https://wa.me/44'+phone+'?text='+textMessage+'%0A%0A%0A'+fileURL
var html = '<!DOCTYPE html> <html>';
html += ' <body>';
html += ' <script language="JavaScript">';
html += 'window.location="'+messageURL+'";'
html += ' </script>';
html += ' </body>';
html += '</html>';