您的位置首页百科知识

怎么取消自动打开StartUp.xls的文件?

怎么取消自动打开StartUp.xls的文件?

StartUp.xls宏病毒现象。 StartUp.xls宏病毒清除方法:第一步:清除C:\Documents and Settings\administrator\Application Data\Microsoft\Excel\XLSTART下的StartUp.xls;第二步:清除C:\Documents and Settings\administrator\Application Data\Microsoft\Excel\的Excel11.exe(约236K),Excel程序会自建该文件。第三步:新建\Documents and Settings\administrator\Application Data\Microsoft\Excel\XLSTART\startup.xls文件,输高漏入以下代码就行了,以后再打开带毒的excel文件就会指昌自动清除excel文件自带的病毒宏戚逗烂代码了Sub auto_open()On Error Resume NextApplication.ScreenUpdating = FalseActiveWindow.Visible = Falsen$ = ActiveWorkbook.NameWorkbooks(n$).Close (False)Application.OnSheetActivate = "StartUp.xls!cop"End SubSub cop()On Error Resume NextDim VBC As ObjectDim Name As StringDim delComponent As VBComponentName = "StartUp"For Each book In WorkbooksSet delComponent = book.VBProject.VBComponents(Name)book.VBProject.VBComponents.Remove delComponentNextEnd Sub