日期:2014-05-18  浏览次数:20406 次

判断多个网络路径是否为空的问题
switch   (IntType)
                {
                        case   1:

                                strFilePath   =   sDoucmentPath   +   strRootDirectory   +   sSubDocumnet   +   strUserDirectory;

                                strFilePath   +=   sFileName;


                                if   (!System.IO.File.Exists(Server.MapPath(strFilePath)))
                                {
                                        strFilePath   =   "http:// "   +   this.Request.Url.Authority   +   sBackUpPath   +   strRootDirectory   +   sSubDocumnet   +   strUserDirectory;
                                        strFilePath   +=   sFileName;
                                }
                           
                                break;
                        case   0:

                                //以服务器中方式传入URL,
                                strFilePath   =   "http:// "   +   this.Request.Url.Authority   +   sDoucmentPath   +   strRootDirectory   +   strUserDirectory;
                                strFilePath   +=   sFileName;
                       
                                if   (!System.IO.File.Exists(strFilePath))
                                {
                                        strFilePath   =   "http:// "   +   this.Request.Url.Authority   +   sBackUpPath   +   strRootDirectory   +   strUserDirectory;
                                        strFilePath   +=   sFileName;
                                }
            &nb