How do I clone menus, insert menus, use popup menus, etc.
Check out G. G. Arun Ganesh’s article Working with Menus in C# on C# Corner.
How do I find the file version of an EXE
Use System.Diagnostics.FileVersionInfo.
How can I programmatically set the initial position of a Form so that it is displayed properly after calling ShowDialog()
In addition to setting the Location property of the form, make sure you also set the StartPosition property of the form to FormStartPosition.Manual.
How can I prevent a control from getting a particular keystroke
You can handle the control’s KeyPress event and indicate the key has been handled. Below is code that prevents a TextBox from getting an ’A’ and the return key. private void textBox1_KeyPress(object sender, System.Windows.Forms.KeyPressEventArgs e) { if(e.KeyChar == (char)13 || e.KeyChar == ’A’) e.Handled = true; }
What is the difference between a form’s Anchor property and a form’s Dock property
G. G. Arun Ganesh discusses these properties in Working with Anchoring and Docking Properties in C# on C# Corner.