CoreWindow.SizeChanged Event


Occurs when the window size is changed.

// Register
event_token SizeChanged(TypedEventHandler<CoreWindow, WindowSizeChangedEventArgs const &> const& handler) const;

// Revoke with event_token
void SizeChanged(event_token const* cookie) const;

// Revoke with event_revoker
SizeChanged_revoker SizeChanged(auto_revoke_t, TypedEventHandler<CoreWindow, WindowSizeChangedEventArgs const &> const& handler) const;
public event TypedEventHandler<CoreWindow,WindowSizeChangedEventArgs> SizeChanged;
function onSizeChanged(eventArgs) { /* Your code */ }
coreWindow.addEventListener("sizechanged", onSizeChanged);
coreWindow.removeEventListener("sizechanged", onSizeChanged);
- or -
coreWindow.onsizechanged = onSizeChanged;
Public Custom Event SizeChanged As TypedEventHandler(Of CoreWindow, WindowSizeChangedEventArgs) Implements SizeChanged

Event Type




The SizeChanged event is exposed to XAML apps as the Window.SizeChanged event and to HTML apps as the window.resize event.

This event occurs when the window size changes or when one of the following properties changes:

Applies to