can u plz tell me what is the code for setting the focus to a checkbox in vb.net 2003 project.
How is this possible?
I have tried checkbox1.setfocus=true but itdoes not work.

Secondly, I wish to fire the click event for a button when I press the enter key. How is this possible? What properties do I need to set?


Recommended Answers

All 2 Replies

In your forms property find AcceptButton and set it to the button you want the enter key to press. You can also set the CancelButton to press if you hit the Esc key.

try to use the javascript for setfocus& keypress...
Unless& untill u use js.its ain't possible to work on vs-2003 or 5,,,
if u want js-reply m back i will forward it to u,.....

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.