Office 365 Multiple Excel Instances

  • Hi - I moved to office 365 today form Windows 10. Have a situation I am investigating.


    Issue

    1.User has multiple instances of excel open. One with a macro, one with other files.

    2.User selects macro button on a workbook to run and macro starts as expected. Macro in this instance is pulling data from a system and writing data to a worksheet on that macro workbook

    3.While macro is running – they select other excel window/instance to multi task and look at other workbooks/ files not related to macro

    4.Macro starts writing to the other excel window/instance and overlays what data is on their non macro file.


    What setting or alternative solution do I need to select/deselect to prevent the macro from bleeding into the other workbook and to keep macro to its dedicated workbook


    Thank you

  • I think you'll find you've confused the new SDI interface with actually having multiple Excel instances open (which is harder than before).

    Rory
    Theory is when you know something, but it doesn’t work. Practice is when something works, but you don’t know why. Programmers combine theory and practice: nothing works and they don’t know why

  • Hi - my macros are used across a company with about 200 people using them. Some have migrated to Office 365 , some have not. In windows 10 the code works as expected, only runs in the instance of excel you have the macro in and does not bleed to another file if you are multi tasking. In 365 it will start writing to any window/instance of excel you select.


    My code does identify the worksheet at the beginning of the code.

    Worksheets("XXX").Activate


    However after that identification of the sheet , my code simply says to copay and past to a column

    EX

    Range("A" & Activecell.row)= "XXX"

    Range("B" & Activecell.row)="BBB"

  • Windows 10 and Office 365 are completely different things. What version of Office are the other computers using?


    If the workbooks are all open in the same instance of Excel, and it's pretty clear from what you describe that they are, then referring to activecell will be the active cell in the active window. You should be qualifying all range references with a specific worksheet object.

    Rory
    Theory is when you know something, but it doesn’t work. Practice is when something works, but you don’t know why. Programmers combine theory and practice: nothing works and they don’t know why