我正在研究一个我以前不记得的问题.我正在使用VS2012 C#
当我添加使用System.IO; 我的主程序一切正常,但是当我将它添加到我的类文件时,它不会让我使用所有的方法.
using System;
using System.Collections.Generic;
using System.IO;
using System.Data.SQLite;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace FoxySearch
{
class FoxySearch
{
File. <<<<----- here i want to add File.Exists("Blablalba")
}
}
Run Code Online (Sandbox Code Playgroud)
由于某种原因,它不会让我添加它.一旦我添加了intellisense关闭的时间段并且没有显示任何选项.当我自己键入它时它显示为红色并且说,
System.IO.File.Exists(string) 是一种方法,但像一个类型一样使用