8

And more specifically, in FSI?

Evgeny Lazin
  • 9,193
  • 6
  • 47
  • 83
Peter
  • 47,963
  • 46
  • 132
  • 181

1 Answers1

16

You can programatically control the clipboard using the Clipboard class in the System.Windows.Forms namespace. (The required assembly is brought in by default to FSI.)

open System.Windows.Forms
Clipboard.SetText("Hello from FSI!")
Chris Smith
  • 18,244
  • 13
  • 59
  • 81
  • I had to modify the entry to my program like so: `[]` according to http://stackoverflow.com/questions/9620712/is-it-possible-to-combine-multiple-attributes-in-f and http://stackoverflow.com/questions/899350/how-to-copy-the-contents-of-a-string-to-the-clipboard-in-c#comment50339862_899374. – Zolomon Dec 01 '16 at 12:08