Hi.
If your form is properly constructed it should be possible.
Let's say this is your form:
<form action="" id="myForm">
<input type="text" value="" name="username" />
<input type="password" value="" name="password" />
<input type="submit" value="Go" />
</form>
You can execute javascript to set the inputs values and also call the form's submit() method:
<script type="text/javascript">
var myForm=document.forms.myForm;
myForm.username.value='Edward';
myForm.password.value='1234567890';
myForm.submit();
</script>
To put that all together, you can execute the javascript either using JSInterface and it's
execJS() method:
Dim myInterface As JSInterface
Dim javascript As String
javascript="var myForm=document.forms.myForm;myForm.username.value='Edward';myForm.password.value='1234567890';myForm.submit();"
myInterface.execJS(myWebView, javascript)
OR you can execute the javascript using the WebView's
LoadUrl() method:
Dim javascript As String
javascript="javascript:var myForm=document.forms.myForm;myForm.username.value='Edward';myForm.password.value='1234567890';myForm.submit();"
myWebView.LoadUrl(javascript)
Martin.