在我的應用程序中,我有兩個System.Windows(WindowsBase)和System.Windows.Forms程序集。我必須使用System.Windows.Application。System.windows和system.windows.forms
但是應用程序正在從System.Windows.Forms中取出Application類。
我指定參考System.Windows;在代碼中,但應用程序仍然從System.Windows.Forms中獲取Application類。
你能幫我一下如何從System.Windows中引用「應用程序」類。
你到底想幹什麼?您的應用程序是Winforms應用程序還是WPF應用程序?這意味着定義了「Main」方法的初始對象是什麼? 'System.Windows.Application.Current'將在Winforms應用中爲空。 –