This project is read-only.

Newbie question about updating the GUI

Jul 20, 2008 at 3:30 PM
I can see how you handle updates to the form, but how do you get data back into it? I'm guessing something like this:

        @accepts(Self(), System.Object, System.EventArgs)
        def _MainForm_Activated(self, sender, e):
            self._showDisplacement.Text = str(self._model.displacement)

But it doesn't work, and adding code to the auto-generated form class keeps getting broken. Is there an example project somewhere, so I can see how this is supposed to work? Just something very simple, but with a button, a text field and a one-member mode class showing how to handle a user event, use that to change the model and then trigger a form update from the model. Preferably implemented in such a way that the form designer isn't going to blow it all away every time you do anything to the project.