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.
メインコンポーネントとして DataGridView を持つフォームがあります。ユーザーがフォームを最大化したときに、DGV のサイズを変更する必要があります。
私がオンラインで読んだように、これはプログラムで行うことはできません。
プログラムは C# で記述され、WinForms を使用します。どのようにしますか?
Anshor プロパティを使用して、4 つの側面すべて (上、右、下、左) に設定します。このようにして、datagridview はフォームと共にサイズ変更されます。
別のオプションは、ドッキング プロパティを使用することです。