Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
25
Centering an undocked DockAreaPane
posted

Hi!

I am working on an application that allows users to select a menu item. Their selection causes a new, undocked pane to open. I am unable to control where the pane opens, though. Can anyone provide some assistance with this? Below is the code that i am using:

 

 

 

 

 

 

 

 

 

 

ctrl.Dock =

DockStyle.Fill;

 

 

 

this._dockableControlPane = new DockableControlPane("ClientPlanMeetingNotes", "Client Plan Meeting Notes", ctrl);

 

 

// create a dock area on the right to contain the rich text
DockAreaPane dockAreaFloat = new DockAreaPane(DockedLocation.Floating);

//TODO: WE WOULD LIKE TO CENTER THE FLOATING THE PANE ON THE PARENT SCREEN HERE

 

 

 

// initialize the size of the dock area
dockAreaFloat.Size = new Size(775, 510);

dockAreaFloat.Key =

"ClientPlanMeetingNotes";

 

 

// finally, add the dock areas to the dock manager
dockAreaFloat.Panes.Add(this._dockableControlPane);

ultraDockManager1.DockAreas.Add(dockAreaFloat);

 

 

this._paneCounter++;

Parents
No Data
Reply
  • 20872
    Suggested Answer
    Offline posted

    Hello ,

    What you could try is to set the the FloatingPosition of your dockAreaFloat or to choose where to place the Floating pane in the screen like the following :

      dockAreaFloat.Float(false, new Rectangle(X,Y, Width, Height));

    X and Y are the coordinates of the upper-left corner of the Rectangle.  So you could adjust X and Y to fit your requierment to be in the center of the screen.

    Hope this helps.

    Sincerely,

    Danko Valkov

    Developer Support Engineer

    Infragistics, Inc.

     

Children
No Data