Help with display issues using Wscript Shell.Exec

Hello, I have written a script for a button which enumerates selected files then uses The Wscript Shell.Exec method to run ExamDiff to compare files across directories, I do this to capture the Exit Code from ExamDiff, everything works great except that it seems that for each call to Shell.Exec, it causes the lister to lose focus and flash, is there any way to overcome this?

Many thanks.

Use WScript.run instead: https://msdn.microsoft.com/en-us/library/d5fk67ky(v=vs.84).aspx

Hi Leo, thanks for replying, I tried it first using Wscript.Run, before switching to Wscript.Exec, and it did the same thing.

What did you use for the intWindowStyle argument?