日期:2014-05-17  浏览次数:20786 次

看不懂代码,有人帮我解释吗?
if   Application(cachename& "index_update ")=false   and   application(cachename& "index ") <> " "   then
show=application(cachename& "index ")
else
dim   rstmp
set   rstmp=conn.execute( "select   skinmain   from   sysskin   where   isdefault= 'true ' ")
show=rstmp(0)
set   rstmp=nothing
call   indexshow()
Application.Lock
application(cachename& "index ")=show
Application(cachename& "index_update ")=false
Application.unLock
if   Application(cachename& "siterefu ") <> " "   then
conn.execute( "update   [bloginfo]   set   siterefu_num= "&Application(cachename& "siterefu "))
end   if
end   if

这个是博客的代码,我实在看不懂这个Application(cachename& "index_update ")=false   ,这个是什么意思,尤其是Application,他起什么作用,我弄不明白!

谢谢大家


------解决方案--------------------
Application 全局变量,一般在global.asa中配置。
------解决方案--------------------
Application一个全局对象 是一个集合,往里面存变量或对象.
------解决方案--------------------
将false这个值存放在 Application集合中. cachename& "index_update " 是个key值,下次调用的时候按key来取. 如 dim bUpdate bUpdate = Application(cachename& "index_update ")
------解决方案--------------------
false
------解决方案--------------------

------解决方案--------------------
cachename应该是个变量把
------解决方案--------------------
好多五角星,我也想要……
楼主,这个application对象就是作为共享变量存在,至于在这里为什么要赋值为false我想要看完整个代码你才能知道吧。这样单独列出一段只能说程序将这个applicaton变量作为一个全局标志吧。