Dieser Inhalt ist in Ihrer Sprache leider nicht verfügbar. Im Folgenden finden Sie die englische Version.

UIPermissionWindow Enumeration

Specifies the type of windows that code is allowed to use.

Namespace: System.Security.Permissions
Assembly: mscorlib (in mscorlib.dll)

public enum UIPermissionWindow
/** @attribute SerializableAttribute() */ 
/** @attribute ComVisibleAttribute(true) */ 
public enum UIPermissionWindow
public enum UIPermissionWindow

 Member nameDescription
AllWindowsUsers can use all windows and user input events without restriction. 
NoWindowsUsers cannot use any windows or user interface events. No user interface can be used. 
SafeSubWindowsUsers can only use SafeSubWindows for drawing, and can only use user input events for user interface within that subwindow. Examples of SafeSubWindows are a MessageBox, common dialog controls, and a control displayed within a browser. 
SafeTopLevelWindowsUsers can only use SafeTopLevelWindows and SafeSubWindows for drawing, and can only use user input events for the user interface within those top-level windows and subwindows.  

When it runs under SafeTopLevelWindows permission, your application:

  • Will show the DNS name or IP address of the Web site from which the application was loaded in its title bar.

  • Will display Balloon tool-tip when it first displays, informing the user that it is running under a restricted trust level.

  • Must display its title bar at all times.

  • Must display window controls on its forms.

  • Cannot minimize its main window on startup.

  • Cannot move its windows off-screen.

  • Cannot use the Opacity property on Form to make its windows less than 50% transparent.

  • Must use only rectangular windows, and must include the window frame. Windows Forms will not honor setting FormBorderStyle to None.

  • Cannot make windows invisible. Any attempt by the application to set the Visible property on its Form objects to False will be ignored.

  • Must have an entry in the Task Bar.

  • Will have its controls prohibited from accessing the Parent property. By implication, controls will also be barred from accessing siblings - i.e., other controls at the same level of nesting.

  • Cannot control focus using the Focus method.

  • Will have restricted keyboard input access, so that a form or control can only access keyboard events for itself and its children.

  • Will have restricted mouse coordinate access, so that a form or control can only read mouse coordinates if the mouse is over its visible area.

  • Cannot set the TopMost property.

  • Cannot control the z-order of controls on the form using the BringToFront and SendToBack methods.

These restrictions help prevent potentially harmful code from spoofing attacks, such as imitating trusted system dialogs.

This enumeration is used by UIPermission.

Windows 98, Windows Server 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition

The Microsoft .NET Framework 3.0 is supported on Windows Vista, Microsoft Windows XP SP2, and Windows Server 2003 SP1.

.NET Framework

Supported in: 3.0, 2.0, 1.1, 1.0