This question already has answers here:
ToggleButton in C# WinForms
(12 answers)
Closed 7 years ago.
I'm currently working on some software in Windows Forms and I was wondering if there's any way to have the buttons stay in their "clicked" state? I want to use them like radio buttons so one would be "clicked" and the other normal, and will switch when the other is selected.
I've looked in the Button properties but I couldn't find anything
You can make checkbox or radiobutton look like a Button
cb.Appearance = Appearance.Button;
Related
This question already has answers here:
How do you simulate Mouse Click in C#?
(7 answers)
Closed 8 months ago.
Suppose I have a ComboBox Control, in which there is dropdown button.
Now I have to open the list without using human interaction by default.
Can I do this ?
Use ComboBox.DroppedDown Property:
comboBox1.DroppedDown = true;
This question already has answers here:
How to make a button appear as if it is pressed?
(3 answers)
Closed 7 years ago.
I have a button to select a tool and I want to make it look pressed after the user clicks it. I am using winforms and I do not want to use Check Box with Button Appearance. How can I achieve that?
You can use a CheckBox with the Appearance property set to Button.
This question already has an answer here:
Capture keyboard inputs without a textbox
(1 answer)
Closed 7 years ago.
I'm working on an university project of a windows forms calculator with c#.
Is fully functional, but the question is.
Can I insert numbers in the main textBox without focusing on it. I want it to work like windows calculator and insert numbers without having to click the textbox.
I've try a lot of methods like using the event Key_Press directly on the form but nothing works.
Ps. Is like windows calculator.
Set the Form.KeyPreview property to true and handle the Form_KeyPress event.
This question already has answers here:
Is there a way to make a UserControl unfocussable?
(6 answers)
Closed 8 years ago.
I want to be able to click on my user control and not have it steal focus from any other control. I know when you click on a label it doesn't steal focus. How can this be done?
Try disabling your control's ControlStyles.Selectable flag.
This question already has answers here:
Closed 12 years ago.
Possible Duplicates:
wpf flat button
Setting Button FlatStyle in WPF
I'm trying to do what Microsoft does allways for their apps that button are like images/labels before hover.
Ex:
alt text http://img709.imageshack.us/img709/3981/hovere.png
hovered normal view
You can write a new control template for the button you can look at the MSDN page or this completely random example I've found on Google.