小编Sta*_*tan的帖子

无法在IIS7上找到CodeDom Provider

我在我的IIS上添加了一个站点但是当我尝试进入默认页面时,我收到以下错误:

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately. 

Parser Error Message: The CodeDom provider type "Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" could not be located.

Source Error: 


Line 12:   <system.codedom>
Line 13:     <compilers>
Line 14:       <compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:6 /nowarn:1659;1699;1701" />
Line 15:       <compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:14 …
Run Code Online (Sandbox Code Playgroud)

iis

17
推荐指数
3
解决办法
3万
查看次数

如何在 Java 中将 zip 文件访问为 zip 文件

我正在尝试读取位于 zip 文件中的 zip 文件本身的 .srt 文件。我成功地读取了 .srt 文件,这些文件位于一个简单的 zip 文件中,代码摘录如下:

    for (Enumeration enume = fis.entries(); enume.hasMoreElements();) {
                ZipEntry entry = (ZipEntry) enume.nextElement();
                fileName = entry.toString().substring(0,entry.toString().length()-4);
try {
                    InputStream in = fis.getInputStream(entry);
                    BufferedReader reader = new BufferedReader(new InputStreamReader(in));
            String ext = entry.toString().substring(entry.toString().length()-4, entry.toString().length());
Run Code Online (Sandbox Code Playgroud)

但是现在我不知道如何访问 zip 文件中的 zip 文件。我尝试使用 ZipFile fis = new ZipFile(filePath) ,其中 filePath 是 zip 文件的路径 + 里面的 zip 文件的名称。它没有识别路径,所以我不知道我是否清楚。

谢谢。

java zip

4
推荐指数
1
解决办法
2125
查看次数

关闭连接和SQL Server DB的连接数

我有一个ASP.net应用程序,我在其中查询SQL Server数据库.查询结束时,我执行以下操作:

reader.Close();
reader.Dispose();
conn.Close();
conn.Dispose();
Run Code Online (Sandbox Code Playgroud)

还是当我继续使用SQL Server时:

SELECT 
    DB_NAME(dbid) as DBName, 
    COUNT(dbid) as NoOfConnections,
    loginame as LoginName
FROM
    sys.sysprocesses
WHERE 
    dbid > 0
GROUP BY 
    dbid, loginame
Run Code Online (Sandbox Code Playgroud)

我可以看到'NoOfConnections'在关闭连接时不断增加,有一段时间我会收到错误,因为我已经打开了100多个连接.如何正确关闭连接

c#

3
推荐指数
1
解决办法
1195
查看次数

标签 统计

c# ×1

iis ×1

java ×1

zip ×1