Detecting data on clipboard

0
0

I am trying to show a button only if there is (text) data on the clipboard.

Wisej.Web.Clipboard.ContainsText is returning false.  So is .ContainsData(Wisej.Web.DataFormats.Text)

Even though the clipboard does infact contain data.

Do I have to do something client side first perhaps to get these methods to work server side?

  • You must to post comments
0
0

The client clipboard is not transferred to the server  automatically – browsers don’t let javascript read the content of the clipboard.

It would have to be done when pressing Ctrl-C  in an editable field. Wisej does it for the DataGridView depending on the value of DGV.ClipboardCopyMode. Doesn’t do it for the TextBox because it doesn’t receive the key events by default. If you enable (handle) KeyPress then you can handle Ctrl-C and copy the value of textBox1.SelectedText to the server side clipboard.

HTH

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.