我通过www.irctc.co.in自动完成机票预订流程 直到现在我能够登录..但是当在下一个表单中指定票证详细信息时,我无法设置“旅程日期”字段(带有文本框的日历)值。
我试过这个
wb.Document.GetElementById("stationFrom").SetAttribute("value", "testStation");
wb.Document.GetElementById("stationTo").SetAttribute("value","testagain");
wb.Document.GetElementById("JDatee1").InvokeMember("onfocus");
wb.Document.GetElementById("JDatee1").SetAttribute("value", "05/31/2012");
wb.Document.GetElementById("JDatee1").SetAttribute("CurrentDate", "31");
wb.Document.GetElementById("JDatee1").SetAttribute("CurrentMonth", "05");
wb.Document.GetElementById("JDatee1").SetAttribute("CurrentYear", "2012");
wb.Document.GetElementById("JDatee1").InvokeMember("onblur");
But after submitting form, date field gets the today's date..
Rest of the field I am able to fill..