Jiew Meng Jiew Meng - 3 months ago 17
C# Question

Handle Copy & Paste (Clipboard) in MVVM

If I want to access the clipboard with MVVM how can I do it?

Answer

SL 4 now supports text clipboard operations. This is transparent in OOB mode and requires user confirmation if not in OOB mode.

You can use Clipboard.GetText() in your view models and commands to retrieve the text content available in the clipboard.