关于IO操作 有没有办法将一个文件的属性设为"只读"? 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 FileInfo fi = new FileInfo( FILENAME ); if( ( fi.Attributes & FileAttributes.ReadOnly ) > 0 ) fi.Attributes ^= FileAttributes.ReadOnly; if( ( fi.Attributes & FileAttributes.Hidden ) > 0 ) fi.Attributes ^= FileAttributes.Hidden; 毕设求助:对于网络爬虫配置文件共享的探索 请问,这段代码,直线怎么没画出来呢? 在DataGridView中可以随意的添加或者删除行 sql like? 多窗体问题 请教有关图像识别的问题 这句SQL哪错了,请高人指点 C# 读取Sybase数据库 中文出现乱码 500分求整站程序 WINDOWS XP不支持。NET??? 新人询问下,有没有办法将整数用2进制,和8,16进制 输出 一个小问题
if( ( fi.Attributes & FileAttributes.ReadOnly ) > 0 )
fi.Attributes ^= FileAttributes.ReadOnly;
if( ( fi.Attributes & FileAttributes.Hidden ) > 0 )
fi.Attributes ^= FileAttributes.Hidden;