bonjour,
je cree un jar avec netbeans et il se lance sans soucis avec java -jar fichier.jar
mais si j'essaye de le creer avec la commande jar cfmv, il ne se lance pas, et voila le message d'erreur :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11 $ java -jar profdep.jar Exception in thread "main" java.lang.NoClassDefFoundError: profdepanne/ProfDepanneApp Caused by: java.lang.ClassNotFoundException: profdepanne.ProfDepanneApp at java.net.URLClassLoader$1.run(URLClassLoader.java:217) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:205) at java.lang.ClassLoader.loadClass(ClassLoader.java:321) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294) at java.lang.ClassLoader.loadClass(ClassLoader.java:266) Could not find the main class: profdepanne.ProfDepanneApp. Program will exit.
voila la liste des fichiers dans le jar cree par netbeans :
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
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91 $ jar tf ProfDepanne.jar META-INF/ META-INF/MANIFEST.MF meta-inf/ meta-inf/services/ profdepanne/ profdepanne/resources/ profdepanne/resources/busyicons/ meta-inf/services/org.jdesktop.application.Application profdepanne/ProfDepanneApp.class profdepanne/ProfDepanneView$1.class profdepanne/ProfDepanneView$10.class profdepanne/ProfDepanneView$11.class profdepanne/ProfDepanneView$12.class profdepanne/ProfDepanneView$13.class profdepanne/ProfDepanneView$14.class profdepanne/ProfDepanneView$15.class profdepanne/ProfDepanneView$16.class profdepanne/ProfDepanneView$17.class profdepanne/ProfDepanneView$18.class profdepanne/ProfDepanneView$19.class profdepanne/ProfDepanneView$2.class profdepanne/ProfDepanneView$20.class profdepanne/ProfDepanneView$21.class profdepanne/ProfDepanneView$22.class profdepanne/ProfDepanneView$23.class profdepanne/ProfDepanneView$24.class profdepanne/ProfDepanneView$25.class profdepanne/ProfDepanneView$26.class profdepanne/ProfDepanneView$27.class profdepanne/ProfDepanneView$28.class profdepanne/ProfDepanneView$29.class profdepanne/ProfDepanneView$3.class profdepanne/ProfDepanneView$30.class profdepanne/ProfDepanneView$31.class profdepanne/ProfDepanneView$32.class profdepanne/ProfDepanneView$33.class profdepanne/ProfDepanneView$34.class profdepanne/ProfDepanneView$35.class profdepanne/ProfDepanneView$36.class profdepanne/ProfDepanneView$37.class profdepanne/ProfDepanneView$38.class profdepanne/ProfDepanneView$39.class profdepanne/ProfDepanneView$4.class profdepanne/ProfDepanneView$40.class profdepanne/ProfDepanneView$41.class profdepanne/ProfDepanneView$42.class profdepanne/ProfDepanneView$43.class profdepanne/ProfDepanneView$44.class profdepanne/ProfDepanneView$45.class profdepanne/ProfDepanneView$46.class profdepanne/ProfDepanneView$47.class profdepanne/ProfDepanneView$48.class profdepanne/ProfDepanneView$49.class profdepanne/ProfDepanneView$5.class profdepanne/ProfDepanneView$50.class profdepanne/ProfDepanneView$51.class profdepanne/ProfDepanneView$52.class profdepanne/ProfDepanneView$53.class profdepanne/ProfDepanneView$54.class profdepanne/ProfDepanneView$55.class profdepanne/ProfDepanneView$56.class profdepanne/ProfDepanneView$57.class profdepanne/ProfDepanneView$6.class profdepanne/ProfDepanneView$7.class profdepanne/ProfDepanneView$8.class profdepanne/ProfDepanneView$9.class profdepanne/ProfDepanneView.class profdepanne/resources/ProfDepanneApp.properties profdepanne/resources/ProfDepanneView.properties profdepanne/resources/about.png profdepanne/resources/busyicons/busy-icon0.png profdepanne/resources/busyicons/busy-icon1.png profdepanne/resources/busyicons/busy-icon10.png profdepanne/resources/busyicons/busy-icon11.png profdepanne/resources/busyicons/busy-icon12.png profdepanne/resources/busyicons/busy-icon13.png profdepanne/resources/busyicons/busy-icon14.png profdepanne/resources/busyicons/busy-icon2.png profdepanne/resources/busyicons/busy-icon3.png profdepanne/resources/busyicons/busy-icon4.png profdepanne/resources/busyicons/busy-icon5.png profdepanne/resources/busyicons/busy-icon6.png profdepanne/resources/busyicons/busy-icon7.png profdepanne/resources/busyicons/busy-icon8.png profdepanne/resources/busyicons/busy-icon9.png profdepanne/resources/busyicons/idle-icon.png profdepanne/resources/gnu.png profdepanne/resources/splash.png profdepanne/resources/tux.png
et voila celle quand je cree le jar :
j'ai pourtant bien les meme, je ne comprends pas pk mon jar ne se lance pas...
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
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93 $ jar tf profdep.jar META-INF/ META-INF/MANIFEST.MF gpl-3.0.odt MANIFEST.MF gplv3-127x51.png Makefile meta-inf/services/ meta-inf/services/org.jdesktop.application.Application bin/profdepanne/ bin/profdepanne/ProfDepanneView$22.class bin/profdepanne/ProfDepanneView$39.class bin/profdepanne/ProfDepanneView$44.class bin/profdepanne/ProfDepanneView$31.class bin/profdepanne/ProfDepanneView$3.class bin/profdepanne/ProfDepanneView$24.class bin/profdepanne/ProfDepanneView$33.class bin/profdepanne/ProfDepanneView$51.class bin/profdepanne/ProfDepanneView$19.class bin/profdepanne/ProfDepanneView$47.class bin/profdepanne/ProfDepanneView$54.class bin/profdepanne/ProfDepanneView$2.class bin/profdepanne/ProfDepanneView$52.class bin/profdepanne/ProfDepanneView$48.class bin/profdepanne/ProfDepanneView$11.class bin/profdepanne/ProfDepanneView.class bin/profdepanne/ProfDepanneView$50.class bin/profdepanne/ProfDepanneView$53.class bin/profdepanne/ProfDepanneView$15.class bin/profdepanne/ProfDepanneView$27.class bin/profdepanne/ProfDepanneView$28.class bin/profdepanne/ProfDepanneView$56.class bin/profdepanne/ProfDepanneApp.class bin/profdepanne/ProfDepanneView$13.class bin/profdepanne/ProfDepanneView$6.class bin/profdepanne/ProfDepanneView$34.class bin/profdepanne/ProfDepanneView$57.class bin/profdepanne/ProfDepanneView$49.class bin/profdepanne/ProfDepanneView$40.class bin/profdepanne/ProfDepanneView$36.class bin/profdepanne/ProfDepanneView$25.class bin/profdepanne/ProfDepanneView$17.class bin/profdepanne/ProfDepanneView$32.class bin/profdepanne/ProfDepanneView$16.class bin/profdepanne/ProfDepanneView$23.class bin/profdepanne/ProfDepanneView$55.class bin/profdepanne/ProfDepanneView$4.class bin/profdepanne/ProfDepanneView$10.class bin/profdepanne/ProfDepanneView$12.class bin/profdepanne/ProfDepanneView$9.class bin/profdepanne/ProfDepanneView$20.class bin/profdepanne/ProfDepanneView$26.class bin/profdepanne/ProfDepanneView$1.class bin/profdepanne/ProfDepanneView$43.class bin/profdepanne/ProfDepanneView$29.class bin/profdepanne/ProfDepanneView$37.class bin/profdepanne/ProfDepanneView$38.class bin/profdepanne/ProfDepanneView$5.class bin/profdepanne/ProfDepanneView$21.class bin/profdepanne/ProfDepanneView$14.class bin/profdepanne/ProfDepanneView$8.class bin/profdepanne/ProfDepanneView$46.class bin/profdepanne/ProfDepanneView$18.class bin/profdepanne/ProfDepanneView$45.class bin/profdepanne/ProfDepanneView$42.class bin/profdepanne/ProfDepanneView$41.class bin/profdepanne/ProfDepanneView$7.class bin/profdepanne/ProfDepanneView$35.class bin/profdepanne/ProfDepanneView$30.class profdepanne-2.7/resources/about.png profdepanne-2.7/resources/busyicons/ profdepanne-2.7/resources/busyicons/busy-icon9.png profdepanne-2.7/resources/busyicons/busy-icon3.png profdepanne-2.7/resources/busyicons/busy-icon2.png profdepanne-2.7/resources/busyicons/busy-icon4.png profdepanne-2.7/resources/busyicons/busy-icon7.png profdepanne-2.7/resources/busyicons/busy-icon13.png profdepanne-2.7/resources/busyicons/busy-icon0.png profdepanne-2.7/resources/busyicons/busy-icon10.png profdepanne-2.7/resources/busyicons/busy-icon14.png profdepanne-2.7/resources/busyicons/busy-icon8.png profdepanne-2.7/resources/busyicons/busy-icon5.png profdepanne-2.7/resources/busyicons/idle-icon.png profdepanne-2.7/resources/busyicons/busy-icon6.png profdepanne-2.7/resources/busyicons/busy-icon1.png profdepanne-2.7/resources/busyicons/busy-icon12.png profdepanne-2.7/resources/busyicons/busy-icon11.png profdepanne-2.7/resources/gnu.png profdepanne-2.7/resources/ProfDepanneApp.properties profdepanne-2.7/resources/ProfDepanneView.properties profdepanne-2.7/resources/splash.png profdepanne-2.7/resources/tux.png
si quelqu'un voit mon erreur, svp.
tres cordialement,
lostsoul
Partager