This week's book giveaway is in the OO, Patterns, UML and Refactoring forum.
We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line!
See this thread for details.
The moose likes Swing / AWT / SWT and the fly likes copy/paste Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "copy/paste" Watch "copy/paste" New topic


glenn lee

Joined: Jan 14, 2004
Posts: 1
hi all, I need copy some JLabels and Graphic2D rectangles from JFrame to system clipboard so that they can be pasted to other application like MSWord, any ideas or pointer? Thanks!
Don Kiddick
Ranch Hand

Joined: Dec 12, 2002
Posts: 580
Things that are text based should just work. Other types are a bit more work. Check out the java.awt.datatransfer package in particular the Transferable interface and the DataFlavor class.
I agree. Here's the link:
subject: copy/paste
It's not a secret anymore!