转载请标明原出处谢谢! http://blog.sina.com.cn/s/blog_a6bd98c90102v3jn.html 全局变量的设定需要在AppDelegete.h和AppDelegate.m文件中进行变量声明。