Intersoft ClientUI Documentation
WindowStartupLocation Property
See Also  Example Send Feedback
Intersoft.Client.UI.Aqua.UXDesktop Namespace > UXWindow Class : WindowStartupLocation Property






Gets or sets a value that indicates how the window should be positioned during startup.

Syntax

Visual Basic (Declaration) 
<CategoryAttribute("Common Properties")>
Public Property WindowStartupLocation As StartupLocation
Visual Basic (Usage)Copy Code
Dim instance As UXWindow
Dim value As StartupLocation
 
instance.WindowStartupLocation = value
 
value = instance.WindowStartupLocation
C# 
[CategoryAttribute("Common Properties")]
public StartupLocation WindowStartupLocation {get; set;}
Delphi 
public read-write property WindowStartupLocation: StartupLocation; 
JScript 
CategoryAttribute("Common Properties")
public function get,set WindowStartupLocation : StartupLocation
Managed Extensions for C++ 
[CategoryAttribute("Common Properties")]
public: __property StartupLocation get_WindowStartupLocation();
public: __property void set_WindowStartupLocation( 
   StartupLocation value
);
C++/CLI 
[CategoryAttribute("Common Properties")]
public:
property StartupLocation WindowStartupLocation {
   StartupLocation get();
   void set (    StartupLocation value);
}

Example

The following example shows how to setup the window to appear with the position centered to the screen.
XAMLCopy Code
<Grid x:Name="LayoutRoot">
        <Intersoft:UXDesktop>
                <local:HomeWindow WindowName="wndHome" 
                                  IsActive="True"
                                  WindowStartupLocation="CenterScreen"/>
        </Intersoft:UXDesktop>
</Grid>

Remarks

You can set a window to be automatically positioned to certain location at startup by setting its WindowStartupLocation property. UXWindow exposes three values that you can apply which is explained below:

  • Auto. The window location will be determined automatically, which is the default value.
  • CenterScreen. The window will be positioned in center relative to the screen.
  • CenterOwner. The window will be positioned in center relative to the owner/parent.

When the Auto mode is used, the desktop manager first checks for the Left and Top property of the window. If an exact location is not specified, the desktop manager automatically calculates the position from the last shown window and position the window cascaded against the previous position. The cascading space can be customized through CascadingSpace property in UXDesktop.

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2012 All Rights Reserved.