I remember doing something similar few years back. I implemented a
WebBrowser
Control, thereby loading the
Website (
Sign up page in your case) inside that.
Then use
WebBrowser.DocumentCompleted
Event[
^], which gets fired when the document is fully loaded.
Now, you can loop through all the controls in the page and assign values to them.
HtmlElementCollection theElementCollection = yourWebBrowserControl.Document.GetElementsByTagName("input");
foreach (HtmlElement curElement in theElementCollection)
{
string controlId = curElement.GetAttribute("id").ToString();
if (controlId == "Email")
{
curElement.SetAttribute("Value", "someEmail@abc.com");
}
}
Here it is looping through all the controls, finds the
Email field by its
Id
and assigning value to that.