Hello, I have this code: AddHandler me.NSTextViewMBS.shouldChangeTextInRange,AddressOf ShouldChangeTextInRange in a TextArea's open event and a method: ShouldChangeTextInRange(tv As NSTextViewMBS, Range As NSRangeMBS, Replacement As String) As Boolean which, for now, just returns true. In my TextArea's close event, there's this: RemoveHandler self.NSTextViewMBS.shouldChangeTextInRange,AddressOf ShouldChangeTextInRange
I get syntax errors with this code, at the AddHandler and RemoveHandler lines. If I change it like this: dim tv As NSTextViewMBS tv=me.NSTextViewMBS AddHandler tv.shouldChangeTextInRange,AddressOf ShouldChangeTextInRange and leave the close event in a single line, the app launches fine and the AddHandler is executed. However, my custom method won't execute and, when closing, the RemoveHandler call triggers an exception stating no AddHandler has been performed prior to removing it (so the AddHandler statement is, in fact, not done). What's wrong here? _______________________________________________ mbsplugins@monkeybreadsoftware.info mailing list %(list_address)s https://ml-cgn08.ispgateway.de/mailman/listinfo/mbsplugins_monkeybreadsoftware.info