Click here to Skip to main content
15,916,692 members
Home / Discussions / C#
   

C#

 
QuestionRe: conversion from string to binary to decimal Pin
Pankaj Garg12-Mar-08 23:47
Pankaj Garg12-Mar-08 23:47 
GeneralRe: conversion from string to binary to decimal Pin
Christian Graus12-Mar-08 20:54
protectorChristian Graus12-Mar-08 20:54 
QuestionRe: conversion from string to binary to decimal Pin
Pankaj Garg12-Mar-08 21:14
Pankaj Garg12-Mar-08 21:14 
GeneralRe: conversion from string to binary to decimal Pin
Christian Graus12-Mar-08 21:43
protectorChristian Graus12-Mar-08 21:43 
GeneralCheck if IDE is open Pin
DJ van Wyk12-Mar-08 18:20
professionalDJ van Wyk12-Mar-08 18:20 
GeneralRe: Check if IDE is open Pin
N a v a n e e t h12-Mar-08 18:44
N a v a n e e t h12-Mar-08 18:44 
GeneralReportViewer control help. Pin
Spacix One12-Mar-08 12:12
Spacix One12-Mar-08 12:12 
GeneralKey Event Handler Pin
BobbyWhiskey12-Mar-08 11:26
BobbyWhiskey12-Mar-08 11:26 
Hi I don't know what happens but i just can't set a KeyPressEventHandler...
I tried every possible way but it just doesnt work, mouse\timer event work but just not any of the press key event work.
Could anyone help me?
My program is really simple, consist of a button that when you press it it plays a sound.
I want that when you press a key it plays the sound too.
So here is my code ( part of it)
I just put a messagebox on the even to test if it works but no...

<br />
public MainWindow() {<br />
            InitializeComponent();<br />
            this.KeyPress += new KeyPressEventHandler(MainWindow_KeyPress);<br />
        }<br />
<br />
void MainWindow_KeyPress(object sender, KeyPressEventArgs e) {<br />
            MessageBox.Show(" Event is working ");<br />
    }<br />
        <br />
private void button1_Click(object sender, EventArgs e) {<br />
            WAVSounds ws = new WAVSounds();<br />
            <br />
            ws.Play("C:\\...\\Snare.wav", ws.SND_FILENAME | ws.SND_ASYNC);<br />
        }<br />


I looked on alot of examples but i don't see anything that is missing.
Thanks alot.
GeneralRe: Key Event Handler Pin
Pete O'Hanlon12-Mar-08 11:55
mvePete O'Hanlon12-Mar-08 11:55 
GeneralRe: Key Event Handler Pin
BobbyWhiskey12-Mar-08 13:58
BobbyWhiskey12-Mar-08 13:58 
GeneralRe: Key Event Handler Pin
Pete O'Hanlon13-Mar-08 2:56
mvePete O'Hanlon13-Mar-08 2:56 
GeneralAutocomplete combobox feature Pin
baranils12-Mar-08 9:55
baranils12-Mar-08 9:55 
GeneralRe: Autocomplete combobox feature Pin
Scott Dorman12-Mar-08 9:58
professionalScott Dorman12-Mar-08 9:58 
GeneralRe: Autocomplete combobox feature Pin
baranils12-Mar-08 10:43
baranils12-Mar-08 10:43 
QuestionDateTime Question Pin
Jammer12-Mar-08 9:32
Jammer12-Mar-08 9:32 
GeneralRe: DateTime Question Pin
Not Active12-Mar-08 10:49
mentorNot Active12-Mar-08 10:49 
GeneralRe: DateTime Question Pin
Jammer12-Mar-08 10:53
Jammer12-Mar-08 10:53 
GeneralRe: DateTime Question Pin
Jammer12-Mar-08 11:13
Jammer12-Mar-08 11:13 
GeneralRe: DateTime Question Pin
Vikram A Punathambekar12-Mar-08 19:20
Vikram A Punathambekar12-Mar-08 19:20 
GeneralRe: DateTime Question Pin
Not Active12-Mar-08 11:17
mentorNot Active12-Mar-08 11:17 
GeneralRe: DateTime Question Pin
Jammer12-Mar-08 11:20
Jammer12-Mar-08 11:20 
GeneralCookie Sets Locally but does not do so on Production Server Pin
dboy22112-Mar-08 9:01
dboy22112-Mar-08 9:01 
QuestionWindows Service running even before windows login Pin
Knowledgestudent12-Mar-08 9:01
Knowledgestudent12-Mar-08 9:01 
GeneralRe: Windows Service running even before windows login Pin
Vikram A Punathambekar12-Mar-08 19:25
Vikram A Punathambekar12-Mar-08 19:25 
QuestionRe: Windows Service running even before windows login Pin
Knowledgestudent12-Mar-08 21:42
Knowledgestudent12-Mar-08 21:42 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.