- Windows 删除文件名中的任何无效字符和空格。无效字符包括:
. " / \ [ ] : ; = ,
- 由于短文件名只能包含一个英文句点 (.),因此,Windows 将删除文件名中的其他英文句点,即使文件名中最后一个英文句点后面是有效的非空格字符,也是如此。例如,Windows 从长文件名
This is a really long filename.123.456.789.txt生成短文件名Thisis~1.txt否则,Windows 将忽略最后一个英文句点,而使用倒数第二个英文句点。例如,Windows 从长文件名This is a really long filename.123.456.789.生成短文件名Thisis~1.789
- 生成短文件名如果需要的话,Windows 将文件名截断为 6 个字符,并在后边附加一个波形符 (~) 和一个数字。例如,创建的每个以"~1"结尾的唯一文件名。复制文件名以"~2"、"~3"等结尾。
- 生成短文件名Windows 将文件扩展名截断为 3 个字符或更短。
- 生成短文件名Windows 将文件名及扩展名中的所有字符转为大写。
例如,"Afile~1.doc"是从"A file.doc"生成的,因为长文件名中包含一个空格。
无法从"A_file.doc"中生成短文件名,因为该文件名中包含的字符少于 8 个并且不包含空格。
短文件名"Alongf~1.txt"是从长文件名"A long filename.txt"生成的,因为长文件名中包含的字符超过 8 个。
3. vs2013下如果想要要出错时定位库函数源代码的位置,需要先加载.pdb文件:在Debug->Options and Settings->Debugging->Symbols下选中Microsoft Symbol Server,在第一次调试时就会从这个服务器把.pdb文件下载下来,你可以把这些文件存到另一个地方,下一次调试时就会优先从本地查找.pdb文件。
有关.pdb文件,官网的阐述如下:
A program database (.pdb) file, also called a symbol file, maps the identifiers that you create in source files for classes, methods, and other code to the identifiers that are used in the compiled executables of your project. The .pdb file also maps the statements in the source code to the execution instructions in the executables. The debugger uses this information to determine two key pieces of information: the source file and line number that are displayed in the Visual Studio IDE and the location in the executable to stop at when you set a breakpoint. A symbol file also contains the original location of the source files, and optionally, the location of a source server where the source files can be retrieved from.
When you debug a project in the Visual Studio IDE, the debugger knows exactly where to find the .pdb and source files for your code. If you want to debug code outside your project source code, such as the Windows or third-party code your project calls, you have to specify the location of the .pdb (and optionally, the source files of the external code) and those files need to exactly match the build of the executables.
详情可以查看:http://msdn.microsoft.com/en-us/library/vstudio/ms241613.aspx#BKMK_Contents