you can try editing the mirc.ini file, which is in the main folder you installed invision to. That holds most of the settings for mIRC, including loaded scripts, everything from the options, colors and alot more.
Scroll down until you find a section that starts with
[rfiles]
after that it'll have a bunch of lines that say 'n*=some invision file'. Delete all of those lines and then goto a sections that starts with
[afiles]
again it'll have a bunch of lines that say 'n*=some invision file'. Delete all of those and then start up mIRC, it'll be just plain mIRC after removing all those files.
Then you can push Alt + O and go down to the 'Other' and click the button that says 'Confirm...'. Where it says 'When closing mIRC, confirm if:' check the box that says 'Always' then click ok and ok. Then push Alt + R and goto the Aliases tab and then goto 'File' and then 'Load...' and naviagate to invision, system, aliases and load all of those. Then goto the Remotes tab, then again to 'File' and then 'Load...' and navigate to the invision, system, remotes folder and manually add each remote one by one until you find the one that is causing the mess up and closing of mIRC, instead of closing now though, it'll bring up a box asking if your sure you wanna close mIRC.