0

Hi.

Is there any way to develop app (WinForms) which will fill out textboxes of web app(Asp.net) with standard data. For example I have in my web application 10 textboxes which have to be filled with cureent date. I do not want to fill every single textbox. What functionality do I want?
- My WinForms application after clicking button (or hot_key event) should fill out 10 text_boxes in browser window with current date.

Sample code or tips and step-by-step solution would be appreciated :)

thanks in advance
q

2
Contributors
2
Replies
3
Views
7 Years
Discussion Span
Last Post by questionary
0

If you are talking about using an application to talk to a browser then you could probably use win32 interop and SendMessage to do that but it would be complicated and you would probably need to do it differently for every different browser.

If you are using the WebBrowser control then you could do somthing like below:

HtmlElement element = webBrowser1.Document.GetElementById("myTextFieldID");
element.InnerText = DateTime.Now.ToString();

Why don't you just initialise the values on the web side with <%=DateTime.Now.ToString("dd/MM/yyyy") %> ?

0

Why don't you just initialise the values on the web side with <%=DateTime.Now.ToString("dd/MM/yyyy") %> ?

because I do not have access to source code. This is not my web apllication - I am only using it...

Edited by questionary: n/a

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.