Community blog feed
Clipboard.Clear … oops
- Blog
- Tim Anderson
- Posted
- 03 Jul 2009 at 15:43
Summary
Bob Warfield is upset because he lost some work. He copied some text in Live Writer, deleted it, then opened Word and tried to paste. No go .. clipboard empty. Frustrating, but is he right to call his post Microsoft: Bad User Experience Is Cultural, on the grounds that Word is designed to clear the clipboard every time it opens? Here’s a bit more information. First, Word does not do that here.
Post extract
Bob Warfield is upset because he lost some work. He copied some text in Live Writer, deleted it, then opened Word and tried to paste. No go .. clipboard empty.
Frustrating, but is he right to call his post Microsoft: Bad User Experience Is Cultural, on the grounds that Word is designed to clear the clipboard every time it opens?
Here’s a bit more information. First, Word does not do that here. Second, if it weren’t that I do equally silly things I’d suggest that it is always risky to entrust the clipboard with your work without a backup.
That said, I can understand why Word might appear to clear the clipboard on start-up. It could be a bug, or it could be an add-in of some kind. The thing is, it is really easy to clear the clipboard in code. Just call EmptyClipboard and you’re done. There are ways to do it in VBA too, via a DataObject, or in .NET via Clipboard.Clear.
As Warfield’s case shows, clearing the clipboard in code can be deeply user-hostile. Should Windows prevent it? Difficult, because if your application or add-in implements clipboard functionality, it is the correct thing to do when the user selects Cut, Copy or Paste.
Lessons? A warning, I guess, not to use the clipboard for any purpose other than a user-initiated clipboard action – though I guess it can be tempting if you are hacking some sort of inter-process data exchange.
Second, when Windows lets you down it is not necessarily Microsoft culture to blame. There is an argument though ... applications that don’t conform to Windows guidelines are a big problem and without them things like User Account Control might not need to exist; and that is Microsoft’s fault in a way, because of the history of Windows, its changing guidelines, and the inability of even Microsoft to stick to them in the past. Maybe Microsoft is partly to blame for the wild culture of third-party Windows apps.
This is a blog entry rather than a comment because Warfield’s blog needs registration to comment, and I am allergic.
Technorati Tags: clipboard,bob warfield,microsoft,word,windows