
Signature
Regards
JTC ^..^
Any other suggestions about creating a custom datetime picker would also be
appreciated.
Dave,
I would believe it is like any other form. First, you would set the
StartPosition of the dialog to FormStartPosition.Manual. You would then set
the Location property to the location that you want it to open. This
location is relative to the screen. You would have to calculate the
position based on the control that is showing the dialog. This can be done
easily with the PointToScreen method on the Control class.

Signature
- Nicholas Paldino [.NET/C# MVP]
- mvp@spam.guard.caspershouse.com
>I have created a custom datetimepicker (following on from a previous thread
> "DateTimePicker color").
[quoted text clipped - 4 lines]
> control
> that opened the dialog.
Dave Anson - 16 Sep 2007 17:12 GMT
> Dave,
>
[quoted text clipped - 6 lines]
> dialog. This can be done easily with the PointToScreen method on the
> Control class.
Thanks for the help. The following code resolved the issue....
// Where "this" is my control and, as suggested,
// the "StartPosition" property of the form
// which will appear as a dialog is set to Manual.
_calendarPopUp.Location = this.PointToScreen(new Point(0, this.Height));
// ShowDialog below the control
this._calendarPopUp.ShowDialog();

Signature
Regards
JTC ^..^