Maybe a Go Bug?


I got some nodes in a workflow.

One of those is a so-say activityset which could contain even more elements itself. If I context-click on this element I show a popup-window containing the elments in the activityset.

After several times of closing and reopening this window,

I always(!) get the following error:

The following exception has occurred:

InvalidOperationException: Cannot call Invoke or InvokeAsync on a control

until the window handle has been created

I guess this could be a threading error?

Somewhere in the doc there was mentioned that the actual version of Go.Net is not threadsafe, am I right?

Maybe some others already encountered this problem and got a solution for it…

Additional info: the context-popupform also contains a GoView with a GoDoc.


I’m not able to reproduce this problem. I had a BackgroundContextClicked event handler create a GoContextMenu with a MenuItem that created a MinimalApp Form, which is a Form that contains a GoView and that initializes itself by creating a couple of nodes. I called Form.Show() to make the form visible.
Could you tell me exactly which .NET runtime you are using? Do you use threads or Timers at all?
Also, you are right that the methods and properties of objects in the GoDiagram library are not thread-safe. However, changes to GoDocuments will call GoView.OnDocumentChanged on the GoView’s thread, since all UI-updating must be done on that Control’s original thread. This avoids a lot of inadvertant problems.


Ok, will be trying to do a simple app which will help you reproducing the error in a couple of days.