.NET

Reply
Active Contributor
Fredrik.Larsen
Posts: 46
Registered: ‎11-28-2012
Message 1 of 3 (390 Views)
Accepted Solution

Autocomplete list disappears

390 Views, 2 Replies
11-28-2012 07:07 AM

I have created a Textbox with autocomplete (suggest) in my UserControl that is put in an Autodesk.AutoCAD.Windows.PaletteSet. When I move my mouse over the dropdown list with the suggestions from autocomplete the list disappears. This makes it impossible to select a value from the list with the mouse. If I move the mouse cursor anywhere else in the usercontrol except over the dropdown list it stays open. How can this be fixed???

 

PS! I have added an eventhandler on textbox.focuslost and it is activated when I move the mouse over the dropdown list, so the textbox loses focus when this happens. (if that is any help)

 

 

Hello Fredrik,

 

I have seen such behavior of a combobox losing its focus when placed in a paletteset.

 

The work-around that seems to resolve the issue is to set the "PaletteSet.KeepFocus" to true in "MouseEnter" event handler of the control and set it to false from the "MouseLeave" event handler of the control.

 

Hope this helps.

 

 

ADN Support Specialist
Balaji_Ram
Posts: 733
Registered: ‎03-21-2011
Message 2 of 3 (348 Views)

Re: Autocomplete list disappears

12-03-2012 08:05 AM in reply to: Fredrik.Larsen

Hello Fredrik,

 

I have seen such behavior of a combobox losing its focus when placed in a paletteset.

 

The work-around that seems to resolve the issue is to set the "PaletteSet.KeepFocus" to true in "MouseEnter" event handler of the control and set it to false from the "MouseLeave" event handler of the control.

 

Hope this helps.

 

 



Balaji
Developer Technical Services
Autodesk Developer Network

Active Contributor
Fredrik.Larsen
Posts: 46
Registered: ‎11-28-2012
Message 3 of 3 (332 Views)

Re: Autocomplete list disappears

12-04-2012 07:00 AM in reply to: Fredrik.Larsen

Thanks, that seems to be the solution. I set the "Palette.KeepFocus" to TRUE from the "MouseLeave" event handler of the textbox.

Post to the Community

Have questions about Autodesk products? Ask the community.

New Post
Announcements
Are You Going To Be @ AU 2014? Feel free to drop by our AU topic post and share your plans, plug a class that you're teaching, or simply check out who else from the community might be in attendance. Ohh and don't forgot to stop by the Autodesk Help | Learn | Collaborate booths in the Exhibit Hall and meet our community team if you get a chance!