Popup Control

G

Guest

hi. for my custom control i would like an editor to popup when the user
clicks a button, similar to the way the calendar opens in the DateTimePicker
control. the editor will need to float above the Control containing my custom
control (e.g. a Form) and not be clipped. what would be the best way to do
this?

thanks

kh
 
O

Otis Mukinfus

hi. for my custom control i would like an editor to popup when the user
clicks a button, similar to the way the calendar opens in the DateTimePicker
control. the editor will need to float above the Control containing my custom
control (e.g. a Form) and not be clipped. what would be the best way to do
this?

thanks

kh

Modeless window with the editing control in it. Set it's position relative to
the clicked button.
Good luck with your project,

Otis Mukinfus
http://www.arltex.com
http://www.tomchilders.com
 
L

Linda Liu [MSFT]

Hi,

Thank you for posting. Form your post, my understanding on this issue is:
how to pop up a custom control in a Windows form. If I'm off base, please
feel free to let me know.

I think you may put your custom control on a borderless Windows form to
simulate the popup behavior. To make a Windows form borderless, set the
FormBorderStyle property to be None, the ShowInTaskbar property False and
the TopMost property True. Then you may show the form and set its position
relative to the button in the button click event handling method.

If you want to hide the control when you click outside the control bound,
you can add the sentence "this.Hide();" in the Deactivate event handling
method.

Hope this is helpful to you. If you have any other concerns or need
anything else, please don't hesitate to tell me.

Sincerely,
Linda Liu
Microsoft Online Community Support

====================================================
When responding to posts,please "Reply to Group" via
your newsreader so that others may learn and benefit
from your issue.
====================================================
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top