473,322 Members | 1,232 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,322 software developers and data experts.

Is there a way to prevent a Button to get the focus?

C# question:

Is there a way to prevent a button from getting the focus and from being
painted with a rectangle of small dots when clicking on it?

Specifically, I have a form with 2 TextBox and a Button: say I am in the
first TextBox and the Button is the next control in the form.

What do I have to do so that tabbing out of the first TextBox skips the
Button over and sets focus to the second Textbox?

Thanks for help.

Eric
Jan 13 '06 #1
4 3043
Have you tried setting the button's TabStop property to false?

Jan 13 '06 #2
Yes, thank you. I had tried that.

But that's not enough.

I'd also like to avoid seeing the small dots signifying focus, appear on the
button when I click on it.

Is that possible?

Thanks.

"Bruce Wood" <br*******@canada.com> wrote in message
news:11**********************@o13g2000cwo.googlegr oups.com...
Have you tried setting the button's TabStop property to false?

Jan 14 '06 #3

"EricL" <er**@lescasse.com> wrote in message
news:43***********************@news.easynet.fr...
Yes, thank you. I had tried that.

But that's not enough.

I'd also like to avoid seeing the small dots signifying focus, appear on
the button when I click on it.

Is that possible?


Why would you want to go out of your way to make it hard for disabled users
to use your app?
Jan 15 '06 #4
I would have to agree with Nick, not just regarding disabled users, but
any and all users.

Systems become easier to use when all of the different applications
work in a similar way. If every application is different, even in a
small way, then it makes the whole system harder to understand and use.
"I have special requirements!" you say, but then everyone says that,
and if everyone does that, then Windows becomes a patchwork of special
applications that all act differently, leaving users confused.

I know it's not the answer you were looking for, but one of my "Laws of
Computing" is "a mediocre standard is better than no standard at all,"
or, stated another way, "your 'better way' had better be 100x better,
otherwise it's not worth breaking the standard."

Jan 16 '06 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
by: Morten Wennevik | last post by:
I'm pretty sure this has been mentioned a few times, but so far I haven't found anything. I am trying to "lock" a program to always focus, non closable etc, but overriding OnDeactivate and...
2
by: Gidi | last post by:
hello, i have a mainForm that has few buttons which open different forms. how can i prevent a form that is already open to be open again ( i don't want to close the mainForm)? thanks....
6
by: Lloyd Dupont | last post by:
I have a web form with multiple part. I do want the user to click the submit button to post back, so I know which functionality was triggered. unfortunately, when the focus is any text box, if...
7
by: MgGuigg | last post by:
Hello all, This is my first time posting a question to this forum, so here is hoping I am following protocol. I am scraping the rust off my old Basic programming skills, and have just recently...
14
by: Ed Jay | last post by:
On a multi-textbox form, linked to an external js, I use onBlur to call: function chkNum(cellname) { var str = document.getElementById(cellname).value.toString(10); if (str < 28 || str > 36)...
3
by: tlyczko | last post by:
Hello, I think what I'm asking for may not be possible, but I'll try anyway. I have MainForm with 3 subforms, one SubForm requires data entry, the other two don't (optional). MainForm has...
4
by: John Smith | last post by:
I have a continuous form. there is a command button with the following code for the OnClick event: DoCmd.OpenForm "frmPlants", , , "PlantsID =" & Me!PlantsID I click the button and frmPlants...
5
by: freelancex | last post by:
Hi, Im new to this forum, and new to scripting in general. Im an ICT Technician for a high school and i am designing a Form in visual basic 2005. The intended purpose of the Form, is to prevent...
2
by: Otis Mukinfus | last post by:
Sorry for the long title. How does one prevent a tab key press from causing the focus to leave a page and move to the navigation bar and tool bars in a browser? I've set the TabIndex on all of...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.