Topics
All
MacOS
(Only)
Windows
(Only)
Linux
(Only, Not)
iOS
(Only, Not)
Components
Crossplatform Mac & Win
Server
Client
Old
Deprecated
Guides
Examples
Videos
New in version:
9.3
9.4
9.5
10.0
10.1
10.2
10.3
10.4
10.5
11.0
Statistic
FMM
Blog
DragDrop.AttachToWindow
Attaches a new drop area to the window.
Component | Version | macOS | Windows | Linux | Server | FileMaker iOS SDK |
DragDrop | 11.0 | Yes | Yes | No | No | No |
Parameters
Parameter | Description | Example |
---|---|---|
WindowRef | Window Reference is the unique OS level window ID. You can obtain this by using the Window.FindByTitle or Window.FindByIndex functions. Pass zero to access the frontmost window. | 0 |
Result
Returns OK or error.
Description
Attaches a new drop area to the window.This disables FileMaker's drop handler and installs the plugin one to the window.
You can't assign a picture or change position on Windows.
On MacOS calls DragDrop.CreateWithWindow internally.
You may need to release via DragDrop.Release later, especially when switching layouts.
Examples
Attach to window of the FileMaker solution:
# SetupDrop attach in file DragTest drag
# let FileMaker build the layout
Pause/Resume Script [ Duration (seconds): ,1 ]
# now add our control
Set Variable [ $$dropview ; Value: MBS("DragDrop.AttachToWindow"; Get(WindowName); "drop") ]
Set Variable [ $result ; Value: MBS( "DragDrop.RegisterDropTypes"; $$dropview; "file") ]
Set Variable [ $result ; Value: MBS( "DragDrop.SetDragActionHandler"; $$dropview; Get ( FileName ); "DragAction") ]
Set Variable [ $result ; Value: MBS( "DragDrop.SetCursor"; $$dropview; 1) ]
See also
- DragDrop.CreateWithWindow
- DragDrop.RegisterDropTypes
- DragDrop.Release
- DragDrop.SetCursor
- DragDrop.SetDragActionHandler
- DragDrop.SetFilePathsToDrag
- Window.FindByIndex
- Window.FindByTitle
Blog Entries
Release notes
- Version 11.0
- Added DragDrop.AttachToWindow function to allow drop to whole window on Windows.
Created 25th November 2020, last changed 18th December 2020
DocumentPicker.SetTrigger - DragDrop.ClearDragActionHandler
Feedback: Report problem or ask question.

Links
MBS Xojo Chart Plugins