#define FILE_ICON "%APPPATH%,1"
%APPPATH% 是指?为什么两边要加上%
走同样的路,发现不同的人生
This %APPPATH% represents the environment variable of the Windows system, which is used to save the path and has nothing to do with C itself
%APPPATH%
is just an ordinary string in C .
This string should be used to represent Windows environment variables. Windows environment variables have percent signs at the beginning and end.
The % sign is only useful when formatting with printf, but only one is needed. If you are not formatting a string, just use it as an ordinary character, a raw character, which has no special meaning.
If you want to get the value of a windows environment variable, you need to use the getenv function
const char* pAppPath = getenv("APPPATH");
Variables in Windows system paths are identified by double percent signs. %APPPATH% should be the path to the application.
You can refer to the process of configuring the development environment in Java under win, and you will understand
This
%APPPATH%
represents the environment variable of the Windows system, which is used to save the path and has nothing to do with C itselfis just an ordinary string in C .
This string should be used to represent Windows environment variables. Windows environment variables have percent signs at the beginning and end.
The % sign is only useful when formatting with printf, but only one is needed. If you are not formatting a string, just use it as an ordinary character, a raw character, which has no special meaning.
If you want to get the value of a windows environment variable, you need to use the getenv function
Variables in Windows system paths are identified by double percent signs.
%APPPATH%
should be the path to the application.You can refer to the process of configuring the development environment in Java under win, and you will understand