skip navigation
  • Product Bundles

    DevCraft

    All Telerik .NET tools and Kendo UI JavaScript components in one package. Now enhanced with:

    • AI Coding Assistants
    • Embedded Reporting
    • Document Processing Libraries
    • SSO Account Sign-in

    Web

    Kendo UI UI for Angular UI for Vue UI for jQuery KendoReact UI for Blazor UI for ASP.NET Core UI for ASP.NET MVC UI for ASP.NET AJAX

    Mobile

    UI for .NET MAUI

    Document Management

    Telerik Document Processing

    Desktop

    UI for .NET MAUI UI for WinUI UI for WinForms UI for WPF

    Reporting

    Telerik Reporting Telerik Report Server

    Testing & Mocking

    Test Studio Telerik JustMock

    CMS

    Sitefinity

    AI Productivity Tools

    AI Coding Assistants

    UI/UX Tools

    ThemeBuilder Design System Kit Templates and Building Blocks

    Debugging

    Fiddler Fiddler Everywhere Fiddler Classic Fiddler Everywhere Reporter FiddlerCore

    Free Tools

    KendoReact Free VB.NET to C# Converter Testing Framework
    View all products
  • Overview
    • Functional UI Testing
    • RESTful API Testing
    • Load Testing
    • Remote Test Execution
    • Agile Teams
    • Web Test Automation
    • Desktop Test Automation
    • Responsive UI Testing
    • Continuous Testing
  • Training
    • Docs and Support
    • Documentation
    • Virtual Classroom
    • Videos
    • Blogs
    • Webinars
    • Whitepapers
    • Case Studies
    • Feedback Portal
    • Technical Support
    • What’s New
    • Roadmap
    • Release Notes
    • Trust Center
    • FAQs
  • Pricing
  • Shopping cart
    • Account Overview
    • Your Licenses
    • Downloads
    • Support Center
    • Forum Profile
    • Payment Methods
    • Edit Profile
    • Log out
  • Login
  • Contact Us
  • Request a demo Try now

Class Window

Inheritance
System.Object
Window
Button
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace: ArtOfTest.Common.Win32
Assembly: ArtOfTest.WebAii.dll

Syntax

public class Window

Constructors

Window(IntPtr)

Declaration
public Window(IntPtr hWnd)
Parameters
System.IntPtr hWnd

Fields

_process

Declaration
protected Process _process
Field Value
System.Diagnostics.Process

Properties

AllChildren

Declaration
public virtual WindowCollection AllChildren { get; }
Property Value
WindowCollection

Caption

Declaration
public virtual string Caption { get; }
Property Value
System.String

ClassName

Declaration
public virtual string ClassName { get; }
Property Value
System.String

Enabled

Declaration
public virtual bool Enabled { get; }
Property Value
System.Boolean

Exists

Declaration
public virtual bool Exists { get; }
Property Value
System.Boolean

Handle

Declaration
public virtual IntPtr Handle { get; }
Property Value
System.IntPtr

IsDialog

Declaration
public virtual bool IsDialog { get; }
Property Value
System.Boolean

IsForegroundWindow

Declaration
public virtual bool IsForegroundWindow { get; }
Property Value
System.Boolean

IsMaximized

Declaration
public virtual bool IsMaximized { get; }
Property Value
System.Boolean

IsMinimized

Declaration
public virtual bool IsMinimized { get; }
Property Value
System.Boolean

IsVisible

Declaration
public virtual bool IsVisible { get; }
Property Value
System.Boolean

Location

Declaration
public Point Location { get; }
Property Value
System.Drawing.Point

OwnerProcess

Declaration
public Process OwnerProcess { get; }
Property Value
System.Diagnostics.Process

ParentWindow

Declaration
public virtual Window ParentWindow { get; }
Property Value
Window

Rectangle

Declaration
public Rectangle Rectangle { get; }
Property Value
System.Drawing.Rectangle

Size

Declaration
public Size Size { get; }
Property Value
System.Drawing.Size

Methods

AttachWrappedWindow()

Declaration
public virtual void AttachWrappedWindow()

Center()

Declaration
public Point Center()
Returns
System.Drawing.Point

Close()

Declaration
public virtual void Close()

ContainsControl(Int32)

Declaration
public virtual bool ContainsControl(int controlId)
Parameters
System.Int32 controlId

Returns
System.Boolean

ContainsText(String, Boolean)

Declaration
public virtual bool ContainsText(string text, bool refreshChildren)
Parameters
System.String text

System.Boolean refreshChildren

Returns
System.Boolean

DetachWrappedWindow()

Declaration
public void DetachWrappedWindow()

EnumHwndAncestors(HWND)

Declaration
public static IEnumerable<HWND> EnumHwndAncestors(HWND hwnd)
Parameters
HWND hwnd

Returns
System.Collections.Generic.IEnumerable<HWND>

GetBitmap()

Declaration
public Bitmap GetBitmap()
Returns
System.Drawing.Bitmap

GetBitmap(RectangleF)

Declaration
public Bitmap GetBitmap(RectangleF targetArea)
Parameters
System.Drawing.RectangleF targetArea

Returns
System.Drawing.Bitmap

GetBitmap(Size)

Declaration
public virtual Bitmap GetBitmap(Size windowSize)
Parameters
System.Drawing.Size windowSize

Returns
System.Drawing.Bitmap

GetHashCode()

Declaration
public override int GetHashCode()
Returns
System.Int32

Overrides
System.Object.GetHashCode()

GetText()

Declaration
public virtual string GetText()
Returns
System.String

GetWindowText()

Declaration
public virtual string GetWindowText()
Returns
System.String

Hide()

Declaration
public virtual void Hide()

IsHwndDialog(HWND)

Declaration
public static bool IsHwndDialog(HWND hwnd)
Parameters
HWND hwnd

Returns
System.Boolean

MakeAbsolute(Rectangle)

Declaration
public Rectangle MakeAbsolute(Rectangle windowRelativeRects)
Parameters
System.Drawing.Rectangle windowRelativeRects

Returns
System.Drawing.Rectangle

MakeRelative(Rectangle)

Declaration
public Rectangle MakeRelative(Rectangle absoluteRects)
Parameters
System.Drawing.Rectangle absoluteRects

Returns
System.Drawing.Rectangle

Maximize()

Declaration
public virtual void Maximize()

Minimize()

Declaration
public virtual void Minimize()

Move(Rectangle, Boolean)

Declaration
public virtual void Move(Rectangle newLocation, bool redraw)
Parameters
System.Drawing.Rectangle newLocation

System.Boolean redraw

OnClick()

Declaration
protected virtual void OnClick()

OnDoubleClick()

Declaration
protected virtual void OnDoubleClick()

OnKeyDown(KeyEventArgs)

Declaration
protected virtual void OnKeyDown(KeyEventArgs e)
Parameters
System.Windows.Forms.KeyEventArgs e

OnKeyPressed(KeyPressEventArgs)

Declaration
protected virtual void OnKeyPressed(KeyPressEventArgs e)
Parameters
System.Windows.Forms.KeyPressEventArgs e

OnKeyUp(KeyEventArgs)

Declaration
protected virtual void OnKeyUp(KeyEventArgs e)
Parameters
System.Windows.Forms.KeyEventArgs e

OnMouseClick(MouseButtons, Int32, Int32, Int32)

Declaration
protected virtual void OnMouseClick(MouseButtons button, int clicks, int x, int y)
Parameters
System.Windows.Forms.MouseButtons button

System.Int32 clicks

System.Int32 x

System.Int32 y

OnMouseClick(MouseEventArgs)

Declaration
protected virtual void OnMouseClick(MouseEventArgs e)
Parameters
System.Windows.Forms.MouseEventArgs e

OnMouseDoubleClick(MouseButtons, Int32, Int32, Int32)

Declaration
protected virtual void OnMouseDoubleClick(MouseButtons button, int clicks, int x, int y)
Parameters
System.Windows.Forms.MouseButtons button

System.Int32 clicks

System.Int32 x

System.Int32 y

OnMouseDown(MouseButtons, Int32, Int32)

Declaration
protected virtual void OnMouseDown(MouseButtons button, int x, int y)
Parameters
System.Windows.Forms.MouseButtons button

System.Int32 x

System.Int32 y

OnMouseDown(MouseEventArgs)

Declaration
protected virtual void OnMouseDown(MouseEventArgs e)
Parameters
System.Windows.Forms.MouseEventArgs e

OnMouseMove(Int32, Int32)

Declaration
protected virtual void OnMouseMove(int x, int y)
Parameters
System.Int32 x

System.Int32 y

OnMouseUp(MouseButtons, Int32, Int32)

Declaration
protected virtual void OnMouseUp(MouseButtons button, int x, int y)
Parameters
System.Windows.Forms.MouseButtons button

System.Int32 x

System.Int32 y

OnMouseUp(MouseEventArgs)

Declaration
protected virtual void OnMouseUp(MouseEventArgs e)
Parameters
System.Windows.Forms.MouseEventArgs e

OnPreMouseClick(MouseEventArgs)

Declaration
protected virtual void OnPreMouseClick(MouseEventArgs e)
Parameters
System.Windows.Forms.MouseEventArgs e

OnPreMouseDown(MouseEventArgs)

Declaration
protected virtual void OnPreMouseDown(MouseEventArgs e)
Parameters
System.Windows.Forms.MouseEventArgs e

OnPreMouseUp(MouseEventArgs)

Declaration
protected void OnPreMouseUp(MouseEventArgs e)
Parameters
System.Windows.Forms.MouseEventArgs e

OnWindowMoved()

Declaration
protected virtual void OnWindowMoved()

RefreshChildren()

Declaration
public virtual void RefreshChildren()

Restore()

Declaration
public virtual void Restore()

SetActive()

Declaration
public virtual void SetActive()

SetFocus()

Declaration
public virtual void SetFocus()

SetPosition(WindowPosition)

Declaration
public virtual void SetPosition(WindowPosition position)
Parameters
WindowPosition position

Show()

Declaration
public virtual void Show()

Update()

Declaration
public virtual void Update()

WaitForVisibility(Boolean, Int32)

Declaration
public void WaitForVisibility(bool visibilityState, int timeout)
Parameters
System.Boolean visibilityState

System.Int32 timeout

WaitForVisibility(Boolean, Int32, Boolean)

Declaration
public bool WaitForVisibility(bool visibilityState, int timeout, bool suppressException)
Parameters
System.Boolean visibilityState

System.Int32 timeout

System.Boolean suppressException

Returns
System.Boolean

Events

Click

Declaration
public event EventHandler Click
Event Type
System.EventHandler

DoubleClick

Declaration
public event EventHandler DoubleClick
Event Type
System.EventHandler

KeyDown

Declaration
public event KeyEventHandler KeyDown
Event Type
System.Windows.Forms.KeyEventHandler

KeyPressed

Declaration
public event KeyPressEventHandler KeyPressed
Event Type
System.Windows.Forms.KeyPressEventHandler

KeyUp

Declaration
public event KeyEventHandler KeyUp
Event Type
System.Windows.Forms.KeyEventHandler

MouseClick

Declaration
public event MouseEventHandler MouseClick
Event Type
System.Windows.Forms.MouseEventHandler

MouseDoubleClick

Declaration
public event MouseEventHandler MouseDoubleClick
Event Type
System.Windows.Forms.MouseEventHandler

MouseDown

Declaration
public event MouseEventHandler MouseDown
Event Type
System.Windows.Forms.MouseEventHandler

MouseMove

Declaration
public event MouseEventHandler MouseMove
Event Type
System.Windows.Forms.MouseEventHandler

MouseUp

Declaration
public event MouseEventHandler MouseUp
Event Type
System.Windows.Forms.MouseEventHandler

PreMouseClick

Declaration
public event MouseEventHandler PreMouseClick
Event Type
System.Windows.Forms.MouseEventHandler

PreMouseDown

Declaration
public event MouseEventHandler PreMouseDown
Event Type
System.Windows.Forms.MouseEventHandler

PreMouseUp

Declaration
public event MouseEventHandler PreMouseUp
Event Type
System.Windows.Forms.MouseEventHandler

WindowMoved

Declaration
public event EventHandler WindowMoved
Event Type
System.EventHandler

Operators

Implicit(HWND to Window)

Declaration
public static implicit operator Window(HWND hWnd)
Parameters
HWND hWnd

Returns
Window

Implicit(Window to HWND)

Declaration
public static implicit operator HWND(Window window)
Parameters
Window window

Returns
HWND

Getting Started
  • Getting Started
  • Videos
  • Whats New
  • Roadmap
Community
  • Forums
  • Blogs
  • Feedback Portal

Copyright © 2018 Progress Software Corporation and/or its subsidiaries or affiliates.
All Rights Reserved.

Progress, Telerik, and certain product names used herein are trademarks or registered trademarks of Progress Software Corporation and/or one of its subsidiaries or affiliates in the U.S. and/or other countries. See Trademarks for appropriate markings.