How to show a popup Form object in fullscreen mode

Started by
-1 comments, last by qileilee 11 years, 8 months ago
Recently, I'm working on a C# project using SlimDX(Direct3D 9) to render 2D images in fullscreen mode. I'd like to use GDI window to do some settings. I've tried as followings, but it does not work, it will exit fullscreen mode when running to this code block. Does any one get some solutions with how to show a child form in fullscreen mode? Thanks. Bad English, hope you get my idea.

// code
Result res = this.Context9.Device.SetDialogBoxMode(true);
if (res.IsSuccess)
{
Panel myFormPanel = new Panel();
Form myForm = new Form();
myForm.Location = new Point(0, 0);
myForm.TopLevel = false;
myForm.TopMost = false;
myForm.ControlBox = false;
myForm.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
myForm.StartPosition = System.Windows.Forms.FormStartPosition.Manual;
myForm.Size = myFormPanel.ClientSize;
myForm.Parent = _form;
myForm.Visible = true;
}

This topic is closed to new replies.

Advertisement