Bonjour,
J'aimerai ajouter un JTextArea dans un message dialog comme suit :
Le problème c'est que j'arrive pas à faire rouler le ScrollPane :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7 JTextArea textArea = new JTextArea(); textArea.setPreferredSize(new Dimension(100, 100)); textArea.setText(flowService.getOutput()); textArea.setEditable(false); JScrollPane scrollPane = new JScrollPane(textArea,JScrollPane.VERTICAL_SCROLLBAR_ALWAYS,JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS); frmClickdeployDeploy.add(scrollPane ); JOptionPane.showMessageDialog(frmClickdeployDeploy,scrollPane);
Merci pour votre aide
Partager