I'm writing code using webclient to post a webpage, that fills out a few data fields using a NameValueCollection which looks something like this:
WebClient client = new WebClient();
NameValueCollection values = new NameValueCollection();
values.Add("TextInputName", "Input here");
values.Add("ComboboxAge", "Input here");
values.Add("RadioButtonGenre", "checked");
using (client)
{
byte[] result = client.UploadValues("https://www.pageofexample.com", "POST", values);
string ResultPage = Encoding.UTF8.GetString(result);
Console.WriteLine(ResultPage);
}
So after the code fills the data fields and posts the webpage it should return a resulting page with some important information on it, however its just returning the same page with all the data boxes filled out except for the comboboxes and radio button which stay set to the default, why do it happens?
Thanks in advance.