could not find or load main class

Due to remember a character encoding error caused not start properly

Operating Environment

win10 English version

jdk 1.8

错误:could not find or load main class

 

The project is Hikvision download a SDK, imported into the IDEA, not expecting to encounter this problem.

Steps are as follows:

1 Download SDK

2 extract to D: \ hikvision \ opensdk-api-demo in

3 Select File .iml introduced through IDEA file-new-module from existing source

 

Analyze the reasons:

This error is usually due to

Like a typo, or class name is incomplete. Compared N times the name is true and correct to exclude this reason.

2 classpath error, we know the path to Java class files are read from the specified classpath. But the idea apparently did not see the call to run the command line (for the idea may be, I do not know, there are heroes know a method, please inform), then Along the way, we can make use of eclipse, see Figure:

 

 

Here we note that the path contains Chinese, I think the system is the English system, wondering if because of this reason.

 

 

The figure we see that the area I set English (United States), so the cause of the problem of the current system does not support the Chinese cause.

So the solution to the problem has two

1: The folder name into English, the problem is solved.

2: The current system code system was changed to China.

Guess you like

Origin www.cnblogs.com/frankyyang/p/12059109.html