Your application, most likely, does not start several instances of itself, you just get several message boxes, since you said that the foreach loop shows a message box with each path. You need to manipulate the string to contain all the paths and then insert them into the message box.
FROM
static void Main(string[] args) { foreach (string path in args) { MessageBox.Show(path); } }
TO
static void Main(string[] args) { string paths = ""; foreach (string path in args) { paths += path + Environment.NewLine; } MessageBox.Show(path); }
Kendy E. Benold
source share