Invoke or BeginInvoke cannot be called on a control until the window handle has been created
- 阅读更多 关于 Invoke or BeginInvoke cannot be called on a control until the window handle has been created
问题 hey guys I get this exception when my application closes. CustomerReadySub is an event that I have subscribed to. The error happens on this line fTypeLabel.Invoke(new MethodInvoker(fuelTypeChosen)); public void CustomerReadySub(object sender, CustomerReadyEventArgs fuel) { // code to handle the event string CustReady = null; //checks what fuel is chosen and then activates the pump fuelType = fuel.SelectedFuel.ToString(); if (!String.IsNullOrEmpty(fuelType)) { fTypeLabel.Invoke(new