File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Java in General and the fly likes cut copy and paste functions Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "cut copy and paste functions" Watch "cut copy and paste functions" New topic

cut copy and paste functions

Burt Reynolds

Joined: Nov 26, 2003
Posts: 2
how do I write code that will use the clip board to cut copy and paste text into or from a input textArea?
Vikalp Setya

Joined: May 10, 2003
Posts: 18
I think every swing text components supports copy/paste/cut to and from clipboard. There's cut(), copy() and paste() methods in JTextArea. For corresponding Action classes, see DefaultEditorKit.cutAction, DefaultEditorKit.copy action. Text cut/copied from textfield goes to the clipboard automatically.

Regards,<br />vikalps
I agree. Here's the link:
subject: cut copy and paste functions
It's not a secret anymore!