how-to- pop up form after context choice selection before insert

I have a context choice popping up a list, and I create the list in the contextchoiceopen()
I pick the element I want and in the
contextchoiceselectedtextinsert, depending on where I am, in some cases I need to close off that context choice list, pop up another dialog whose values are based on the choice made, and select some 'stuff', and put the results back
in the edit control.

When I try to pop up the window, the context llist is 'stuck' with focus, the new
window (on-top but with focus locked away) never has foucs and then I have to kill the app as noone can ever get back focus.

I tried the editcontrol1.closecontextchoice(), didn't work - the new form seems not
to have focus 'ever' so it can't do it's work.

FYI this form lives in a C++ .dll and I'm using it via p-invoke, but that I don't
think is the problem.

Let me know if theres a simple fix to kill the box or leave focus

This is what i want to do:
private void editControl1_ContextChoiceSelectedTextInsert(
Syncfusion.Windows.Forms.Edit.Interfaces.IContextChoiceController sender,
Syncfusion.Windows.Forms.Edit.ContextChoiceTextInsertEventArgs e) {

string curWord = this.editControl1.GetCurrentWord();
if (e.SelectedItem != null) {
string selWord = e.SelectedItem.Text ;

switch (specialMode) {
case "bracket":
e.Cancel=true;

if(this.editControl1.ContextChoiceController.IsVisible) {
this.editControl1.CloseContextChoice();|}

string stElemList = Tm1ApiDef.OpenSubsetEditor(this.ServerName, selWord , false) ;
if (stElemList != "") {
this.editControl1.InsertText(this.editControl1.CurrentLine,this.editControl1.CurrentColumn,stElemList);
}
break;

etc.

1 Reply

AD Administrator Syncfusion Team January 8, 2007 05:44 PM UTC

Hi David,

Our apologies for the delayed response. Your Direct-Trac incident 30454 has been updated with the patch for this issue. Please test your application with this build and let me know if this resolves your problem.

Thanks for your patience.

Regards,
Ebenezer.P


Loader.
Up arrow icon