You would use this method to put data into the clipboard. This is done by accessing the clipboardData or dataTransfer objects during an event handler. You can only store textual values into the clipboard with this method. However they may be the raw text data itself or a description of the URL where non-text data can be found.
The method takes two arguments. The first can be set to the value "TEXT" or "URL" to indicate which kind of data is being stored. The second argument is the data to be added to the transfer object.
This method returns a Boolean value indicating success or failure of the setData() call.
Prev | Home | Next |
dataTransfer.getData() | Up | Date and time |
JavaScript Programmer's Reference, Cliff Wootton Wrox Press (www.wrox.com) Join the Wrox JavaScript forum at p2p.wrox.com Please report problems to support@wrox.com © 2001 Wrox Press. All Rights Reserved. Terms and conditions. |