-
Bug
-
Resolution: Duplicate
-
P2
-
None
-
1.4.0
-
generic
-
generic
IllegalArgumentException is thrown when i tried to copy paste some text in Notepad demo.
Steps to reproduce:
1) Run Notepad demo
2) Type some text in the Notepad window.
3) Select a word from the text you typed by doubleclicking on it.
4) Copy it
5) Again select the same word by double clicking on it
6) Hit Paste button. Exception is thrown.
The following exception was thrown:
java.lang.IllegalArgumentException: getTransferData() returned null
at java.awt.datatransfer.DataFlavor.getReaderForText(DataFlavor.java:613
)
at javax.swing.plaf.basic.BasicTextUI$TextTransferHandler.importData(Bas
icTextUI.java:2148)
at javax.swing.TransferHandler$TransferAction.actionPerformed(TransferHa
ndler.java:724)
at javax.swing.text.JTextComponent.paste(JTextComponent.java:1079)
at javax.swing.text.DefaultEditorKit$PasteAction.actionPerformed(Default
EditorKit.java:1219)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:16
05)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(Abstra
ctButton.java:1659)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel
.java:405)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:251
)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonL
istener.java:247)
at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:2
30)
at java.awt.Component.processMouseEvent(Component.java:4861)
at java.awt.Component.processEvent(Component.java:4687)
at java.awt.Container.processEvent(Container.java:1299)
at java.awt.Component.dispatchEventImpl(Component.java:3459)
at java.awt.Container.dispatchEventImpl(Container.java:1361)
at java.awt.Component.dispatchEvent(Component.java:3326)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3146
)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:2866)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:2824)
at java.awt.Container.dispatchEventImpl(Container.java:1335)
at java.awt.Window.dispatchEventImpl(Window.java:1250)
at java.awt.Component.dispatchEvent(Component.java:3326)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:437)
at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:14
0)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:126)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:121)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
ruchika.mehdiratta@Eng 2001-01-25
Steps to reproduce:
1) Run Notepad demo
2) Type some text in the Notepad window.
3) Select a word from the text you typed by doubleclicking on it.
4) Copy it
5) Again select the same word by double clicking on it
6) Hit Paste button. Exception is thrown.
The following exception was thrown:
java.lang.IllegalArgumentException: getTransferData() returned null
at java.awt.datatransfer.DataFlavor.getReaderForText(DataFlavor.java:613
)
at javax.swing.plaf.basic.BasicTextUI$TextTransferHandler.importData(Bas
icTextUI.java:2148)
at javax.swing.TransferHandler$TransferAction.actionPerformed(TransferHa
ndler.java:724)
at javax.swing.text.JTextComponent.paste(JTextComponent.java:1079)
at javax.swing.text.DefaultEditorKit$PasteAction.actionPerformed(Default
EditorKit.java:1219)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:16
05)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(Abstra
ctButton.java:1659)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel
.java:405)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:251
)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonL
istener.java:247)
at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:2
30)
at java.awt.Component.processMouseEvent(Component.java:4861)
at java.awt.Component.processEvent(Component.java:4687)
at java.awt.Container.processEvent(Container.java:1299)
at java.awt.Component.dispatchEventImpl(Component.java:3459)
at java.awt.Container.dispatchEventImpl(Container.java:1361)
at java.awt.Component.dispatchEvent(Component.java:3326)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3146
)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:2866)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:2824)
at java.awt.Container.dispatchEventImpl(Container.java:1335)
at java.awt.Window.dispatchEventImpl(Window.java:1250)
at java.awt.Component.dispatchEvent(Component.java:3326)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:437)
at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:14
0)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:126)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:121)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:99)
ruchika.mehdiratta@Eng 2001-01-25
- duplicates
-
JDK-4406212 copy from\paste to a JTextArea that has highlighted text throws IAE
-
- Closed
-