Use VB to distinguish between an xlsx event from C# Interop or Excel program
问题 I have an event that I want triggered when a user closes a .xlsx file. I also have a C# program that regularly checks the content within that same file. The problem I have is that when my C# program (which uses Interop) closes the .xlsx file, it triggers my VB code. Is there a way to isolate access to the excel file so that I know it was edited within the Excel program? I only want my VB code triggered when a user edits the file within Excel. Thanks 回答1: I decided to simply have my C# program