2010-09-28 6 views

Odpowiedz

1

Całkowicie się zgadzam. Nie mogę uwierzyć, że nie naprawić go w VS 2010.

Ale tylko FYI:

Ten jeden jest zamknięty Microsoft Connect.

Ten jeden wydaje się być nadal aktywny i ma obejście (co nie jest warte czasu dla mnie): Microsoft Active

Chyba ten mówi, jak poważnie Microsoft bierze to: problemem jest wciąż wybitnym od 5 lat temu: 283618

3

Znalazłem to również bardzo irytujące, więc sam szukałem rozwiązania. I przyszedł z małym app konsoli pisałem, z następującego kodu:

using System; 
using System.Collections.Generic; 
using System.Linq; 
using System.Runtime.InteropServices; 
using System.Text; 
using System.Threading; 
using System.Windows.Forms; 


internal class Program 
{ 
    // For Windows Mobile, replace user32.dll with coredll.dll 
    [DllImport("user32.dll", SetLastError = true)] 
    static extern IntPtr FindWindow(string lpClassName, string lpWindowName); 

    // Find window by Caption only. Note you must pass IntPtr.Zero as the first parameter. 
    [DllImport("user32.dll", EntryPoint = "FindWindow", SetLastError = true)] 
    static extern IntPtr FindWindowByCaption(IntPtr ZeroOnly, string lpWindowName); 

    [DllImport("user32.dll")] 
    //  static extern bool ShowWindow(IntPtr hWnd, ShowWindowCommands nCmdShow); 
    static extern bool ShowWindow(IntPtr hWnd, int nCmdShow); 

    internal static void Main(string[] args) 
    { 
    do 
    { 
     Console.Title = "Waiting..."; 
     Console.WriteLine("Waiting..."); 
     IntPtr hwnd = FindWindowByCaption(IntPtr.Zero, "File Modification Detected"); 
     while ((int)hwnd == 0) 
     { 
      Thread.Sleep(500); 
      hwnd = FindWindowByCaption(IntPtr.Zero, "File Modification Detected"); 
     } 

     Console.Title = "Found one, kill it..."; 
     Console.WriteLine("Found one, kill it..."); 
     // ShowNormal = 1 
     // Show = 5 
     ShowWindow(hwnd, 5); 
     SendKeys.SendWait("{ENTER}"); 
     Thread.Sleep(500); 
     hwnd = IntPtr.Zero; 
    } while (true); 

    } 
} 

Jeśli uruchomić ten program, to czeka na tych pop-upów i kliknie Reload automatycznie.

6

Spróbuj VSCommands 2010 Lite, pozwala, aby przeładować wszystkie projekty:

enter image description here

+1

Thanx! Dokładnie to, czego potrzebowałem! –