I am new to coding and for one of my first projects I have to read information from a digital caliper and display it in a text box on a web application. I found code from another project some else created where they are using a windows form. I am using visual studio 2013 and I am modifying their code to work with a web application instead of a windows form. The trouble I am having is that they have two lines of code that I do not understand and cannot seem to find an answer of how to modify them to work for my needs. the code is
this.BeginInvoke(new EventHandler(delegate { SetTheText(strErg); }));
Application.DoEvents();
The problem is that both BeginInvoke and DoEvents() have an error saying there is no definition for either. Is there a way to modify this to a web application? Or is there a way to make the definition know for both of these?
It may seem trivial to many but I cannot figure it out. Any help would be greatly appreciated!
I have the following using statements included using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.UI; using System.Web.UI.WebControls; using System.ComponentModel; using System.Data; using System.Drawing; using System.Text; using System.Threading; using System.IO.Ports; using Telerik.Web.UI; using System.Windows.Forms; using System.Web.Services.Protocols; using System.Web.Services
;
using
statements at the top of the file? Does it includeSystem.Windows.Forms
? – gunr2171