Je n'arrive pas à exécuter ce bout de code:
j'obtiens la réponse:
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16 package pack2; import javax.swing.*; public class Main { public static void main(String[] args) { String imgLocation = "Back24.gif"; java.net.URL imageURL = JButton.class.getResource(imgLocation); if (imageURL == null) { System.err.println("Resource not found: " + imgLocation); } } }
Donc j'ai fait un copie past de Back24.gif partout ou je pouvais dans le projet mais rien n'y fait.
Code : Sélectionner tout - Visualiser dans une fenêtre à part Resource not found: Back24.gif
Si quelqu'un pouvait me dire comment il s'y prend.
Partager