Click here to Skip to main content
15,922,584 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
1. how to add the FontDialog's contents to my form?
(I don't want to create a button that displays the FontDialog ... I need to add the dialog's contents as icons to my form like " a button B and a button I ...etc").

2. how to DISPLAY a running timer on my Form?
(starts with 0 and increases every second)

3. how to remove the sound that appears when I press the Enter button?
( this is the event code:

C#
private void TextBox_KeyUp(object sender, KeyEventArgs e)
       {
           if (e.KeyCode == Keys.Enter)
           {
               // Do Something
           }
       }


but when I press Enter a noisy annoying sound like an error MessageBox rises... how to get rid of it?).

I appreciate any help :)
thanks guys,
Posted
Comments
CodingLover 27-Sep-11 4:13am    
Why don't you take a one at a time, and give a try? Show your effort here, so we can comment on you. :)

1 solution

1. You can't – these dialogs are all of a piece and created by the OS. Ask for one on a different OS and it may look different. You will have to create tool buttons and other controls yourself.

2. For a pure UI timer, use System.Windows.Forms.Timer or whatever the WPF equivalent is (it will be in your toolbox if you are using a graphical IDE), set its interval to 1000ms and update a label in the update event. This timer runs in the UI thread and is not super accurate, so if you're actually timing something as part of a data management process you may want to use other techniques, but your question implies it is just a UI level thing.

3. There should be no sound from Enter. Do you have something else on the form hooked up to Enter (for example a button set as the form's AcceptButton) which is putting up a message box?
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900