excel突然停止执行宏

时间:2018-01-11 12:11:56

标签: excel excel-vba loops crash corrupt vba

我已经为调查创建了一个表单,它有500多个问题,它根据提供的条件从工作表中提取。它还有一个组合框,可以提取字母数字的问号。一旦调查开始并完成,如果有任何问题,未答复将以另一种形式显示,用户可以返回表格并回答它们。在回答这些问题时,excel将多次运行循环以验证条件,并且在特定问题时它会在提取问题编号时停止工作。 没有错误消息,没有调试选项代码停止执行而没有任何跟踪。

<DirectoryRef Id="BIN">
  <Component Id="MyService" Guid="*" SharedDllRefCount="yes">
    <File Id="MyService.exe" Name="MyService.exe" KeyPath="yes" Vital="no" Compressed="default" DiskId="1" Source="$(var.DirDotfuscated)\MyService.exe" />
    <ServiceControl Id="Install" Name="MyService" Start="install" Stop="install" />
    <ServiceControl Id="Uninstall" Name="MyService" Stop="uninstall" Remove="uninstall" />
    <ServiceInstall Id="NewServiceInstall2" Name="MyService" DisplayName="My Service" Type="ownProcess" Interactive="no" Start="auto" ErrorControl="normal" Description="My service" Vital="no" />
  </Component>
  <Component Id="Xms_HostService_Files" Guid="*" SharedDllRefCount="yes">
    <File Id="MyService.exe.config" Name="MyService.exe.config" Vital="no" Compressed="default" DiskId="1" Source="$(var.DirDotfuscated)\MyService.exe.config" />
    <File Id="MyServiceCommon.dll" Name="MyServiceCommon.dll" Vital="no" Compressed="default" DiskId="1" Source="$(var.DirDotfuscated)\MyServiceCommon.dll" />
    <File KeyPath="yes" Id="MyServiceCore.dll" Name="MyServiceCore.dll" Vital="no" Compressed="default" DiskId="1" Source="$(var.DirDotfuscated)\MyServiceCore.dll" />
  </Component>
</DirectoryRef>

这是代码停止的行,然后表单也从表单中消失。 RQID值大多数时间是276,并且在从50到50的循环中需要大量验证过程才能达到此值。是因为文件已损坏。

此外,当我双击UserForm1进行验证时,它会重新启动excel。

它发生在以前工作正常的多个版本的文件中。此外,我从我的客户端收到第一个有问题的文件。她的文件是否有任何方式可能损坏我的Excel应用程序或者这是由Add Ins引起的?

0 个答案:

没有答案