Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
WPFについて質問があります。以下に 2 つのコードを示します。1 つ目は、Windows フォーム アプリケーション用であり、動作します。2 つ目は WPF アプリケーション用で、機能しません。
誰かが私が間違っていることを説明できますか?
public WpfLogger(String fileName, Form form, TextBox textBox)
public WpfLogger(String fileName, Wpf wpf, TextBox textBox)
という名前のクラスはありませんWpf。あなたが同等のものを探しているなら
Wpf
System.Windows.Forms.Form、それはでしょうSystem.Windows.Window。
System.Windows.Forms.Form
System.Windows.Window
ところで、WPF はそれ自体が複雑なフレームワークです (未経験者には適していません)。最初にいくつかのコンソール アプリケーションで練習して、C# と OOP の基本を学ぶことをお勧めします。