1

I have a IToolControl derived control which contains a c# TextBox. In the IToolControl::OnSetFocus function documentation, it states that you need to call ICompletionNotify::SetComplete() when it's finished to let the application know that the control should lose focus.

On another IToolControl ComboBox control, I called the SetComplete() function on the DropDownClosed event.

On which TextBox event should I call ICompletionNotify.SetComplete()?

1 Answer 1

1

I guess an appropriate moment to call ICompletionNotify.SetComplete for a TextBox would be upon the user hitting the Enter key. That could be handled by subscribing to the KeyDown event and checking whether the KeyCode in event arguments equals to Keys.Enter.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.