Window.GetTop
-------------

Queries Y coordinate of a window.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Window](component_Window.md) | [2.8](newinversion28.md) | ✅ Yes | ✅ Yes | ❌ No | ❌ No | ❌ No |

MBS( "Window.GetTop"; WindowRef ) 

**MBS**( **"Window.GetTop";** /\* Queries Y coordinate of a window. \*/  
**$WindowRef**) /\* Window Reference is the unique OS level window ID. You can obtain this by using the [Window.FindByTitle](WindowFindByTitle.md) or [Window.FindByIndex](WindowFindByIndex.md) functions. Pass zero to access the frontmost window.e.g. 0 \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| WindowRef | Window Reference is the unique OS level window ID. You can obtain this by using the [Window.FindByTitle](WindowFindByTitle.md) or [Window.FindByIndex](WindowFindByIndex.md) functions. Pass zero to access the frontmost window. | 0 |

### Result

Returns top of window.

### Description

Queries Y coordinate of a window.  
See also [Window.GetLeft](WindowGetLeft.md), [Window.GetWidth](WindowGetWidth.md) and [Window.GetHeight](WindowGetHeight.md).  
### Examples

Get position of front window:

 MBS ( "[Window.GetLeft](WindowGetLeft.md)"; 0 ) &amp; "/" &amp; MBS ( "Window.GetTop"; 0 )  
### See also

- [Screen.Left](ScreenLeft.md)
- [Screen.Width](ScreenWidth.md)
- [Window.FindByIndex](WindowFindByIndex.md)
- [Window.FindByTitle](WindowFindByTitle.md)
- [Window.GetHeight](WindowGetHeight.md)
- [Window.GetLeft](WindowGetLeft.md)
- [Window.GetTag](WindowGetTag.md)
- [Window.GetWidth](WindowGetWidth.md)
- [Window.Parent](WindowParent.md)
- [Window.SetTag](WindowSetTag.md)

### Example Databases

- [RemoteControl/Windows List](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/RemoteControl/Windows%20List.shtml#1ScriptAnchor_)
- [Window/Schedule Moved Trigger](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Window/Schedule%20Moved%20Trigger.shtml#1ScriptAnchor_)
- [Window/Window Position and Size](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Window/Window%20Position%20and%20Size.shtml#1ScriptAnchor_)

### Blog Entries

- [Script trigger for moving window](https://www.mbsplugins.de/archive/2022-10-07/Script_trigger_for_moving_wind/monkeybreadsoftware_blog_filemaker)

### FileMaker Magazin

- [Ausgabe 4/2025, Seite 29](https://filemaker-magazin.de/neuigkeit/4297-Appetithappen-FMM_202504)

This function checks for a license.

Created 18th August 2014 , last changed 26th December 2019

  
[Window.GetToolbarVisible](WindowGetToolbarVisible.md) - [Window.GetTopMost](WindowGetTopMost.md)

[HTML Version](WindowGetTop.shtml)