my delete button on my keyboard stopped working in all applications.is there a way in vb to see if its even getting through when i press it?
Printable View
my delete button on my keyboard stopped working in all applications.is there a way in vb to see if its even getting through when i press it?
Yep.
Put this code into a form:
Try clicking delete...VB Code:
Private Sub Form_KeyDown(KeyAscii As Integer) MsgBox KeyAscii End Sub
You should get a msgbox with a number.
When i try to run that code i get
Compile Error:
Procedure declaration does not match description of event or precedure having the same name
???????????
If it is VB6 then try this:
VB Code:
Option Explicit Private Sub Form_KeyUp(KeyCode As Integer, Shift As Integer) MsgBox KeyCode End Sub Private Sub Form_Load() KeyPreview = True End Sub
Not sure but think that Delete key is 46...
VB Code:
Private Sub Form1_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles MyBase.KeyDown MessageBox.Show(e.KeyCode) End Sub
Thanks NoteMe, your code worked, the others didnt.and was the others wrote for .net? and whats the differance?
.NET is a new programming technology, but this topic is outside the scope of this thread.Quote:
Originally posted by toogogtobetrue
.and was the others wrote for .net? and whats the differance?
Uh-oh... I'm talking like an author now. :sick:
sheesh, im just now starting to learn vb6, thats the only compiler i got.if i learn vb6, will i have to start all over to learn .net?seems that way, might as well stop now and go buy a .net compiler and start all over huh.
If you start off on VB.NET without knowing VB6 first, you'll have a better learning curve than if you knew VB6 previously.Quote:
Originally posted by toogogtobetrue
sheesh, im just now starting to learn vb6, thats the only compiler i got.if i learn vb6, will i have to start all over to learn .net?seems that way, might as well stop now and go buy a .net compiler and start all over huh.
If you're gonna bother, learn C++.Quote:
Originally posted by toogogtobetrue
sheesh, im just now starting to learn vb6, thats the only compiler i got.if i learn vb6, will i have to start all over to learn .net?seems that way, might as well stop now and go buy a .net compiler and start all over huh.
VB6 is still plenty powerful. .NET has yet to prove itself as viable(25 MB run-time files makes VB6's runtimes relatively nothing). Some call it a failure already.
LOL, we are doing C++ in Software Design & Development and we did a class vote on whether to continue with C++ (Only making console apps currently, would go onto Forms and stuff) or goto VB, it was a unanimous decision to goto VB.Quote:
Originally posted by DiGiTalErRoR
If you're gonna bother, learn C++.
VB6 is still plenty powerful. .NET has yet to prove itself as viable(25 MB run-time files makes VB6's runtimes relatively nothing). Some call it a failure already.
VB.NET is quite nice, stick to it, it makes life very easy i found in many situations, accessing the registry is dead simple with .NET, with 6, you needed the API stuff and nice things such as the Cryptography classes are nice and handy, pitty it's confusing to actually use.
With future service packs, the .NET framework will be bundled with Windows so that's not an issue, it is very viable and Microsoft is putting all it's attention into .NET because apparently, Longhorn is built using .NET, at least the early builds were.