make a text box not selectable (1 Viewer)

Darth Vodka

Registered User.
Local time
Today, 00:10
Joined
Sep 25, 2007
Messages
344
i think i'm going mad

i have a text box that is Enabled=no and Locked=Yes, but i can still select it and it ruins the look of things as it's in the background...

have i missed something..is there an option to make it unselectable?
 

Brianwarnock

Retired
Local time
Today, 00:10
Joined
Jun 2, 2003
Messages
12,701
I don't know how to prevent selection with the mouse etc, but do you mean as a tab stop? If yes then that's in the properties.

Actually enabled=no prevents selection with a pointer or a tab, so how are you selecting the field?
Brian
 
Last edited:

rainman89

I cant find the any key..
Local time
Yesterday, 19:10
Joined
Feb 12, 2007
Messages
3,015
if you have it set as a tab stop i believe that it can be selected
 

Brianwarnock

Retired
Local time
Today, 00:10
Joined
Jun 2, 2003
Messages
12,701
Incase I was confused I just tested and with Enabled = no I could not select the txtbox any which way.

Brian
 

missinglinq

AWF VIP
Local time
Yesterday, 19:10
Joined
Jun 20, 2003
Messages
6,423
  • Double check that you're looking at the properties for the right textbox
  • Double check that it actually is Enabled=no and Locked=Yes and not Enabled=yes and Locked=no (which is the default)

If the above is in fact correct, delete the textbox and recreate it; it may be corrupted. As Brian said, it should not be able to receive focus by tabbing or clicking.
 

Darth Vodka

Registered User.
Local time
Today, 00:10
Joined
Sep 25, 2007
Messages
344
thanks for the replies

i was selecting it with the mouse and it really is enabled=no, locked=yes

i think it may be that i have conditional formatting on it?

if i switch the conditional formatting off, i can't select it?
 

Darth Vodka

Registered User.
Local time
Today, 00:10
Joined
Sep 25, 2007
Messages
344
i can think of a clumsy solution, put a non conditional formatted box over it...

ugh
 
M

Mike375

Guest
Noticed he Locked Yes.

For me, if Enable No and then Locked Yes.....the field no longer greys out but you still can't get to it, by tab or mouse.
 
M

Mike375

Guest
Conditional formatting changes things.

With Enable No Locked Yes and Conditional formatting the field just acts like it is locked.

Can be selected by mouse and tab.....and the conditional formatting works

Went back to Design to make sure nothing had changed....still Enable No Locked Yes
 
M

Mike375

Guest
Now that we have Enable/Select sorted out, I have forgotten what the original problem was:D
 

Brianwarnock

Retired
Local time
Today, 00:10
Joined
Jun 2, 2003
Messages
12,701
He doesn't want to be able to select it, its in the background, selecting it spoils the look of things!!!, and he wants conditional formatting. Perhaps the full story in words of one syllable would help us, me anyway, understand whats going on and why.

Brian
 
M

Mike375

Guest
have i missed something..is there an option to make it unselectable?

What about a simple little On Click macro Echo No/GoToControl Click on the field and the cursor won't be seen to land

And select Tab Stop as No

Just tried that and the cursor appears for a split second the is gone.
 

Darth Vodka

Registered User.
Local time
Today, 00:10
Joined
Sep 25, 2007
Messages
344
have i missed something..is there an option to make it unselectable?

What about a simple little On Click macro Echo No/GoToControl Click on the field and the cursor won't be seen to land

Just tried that and the cursor appears for a split second the is gone.

i thought about code to redirect if you clicked, but decided a covering text boxes was less of a mallet to smash the egg

thanx anyways, personally i blame whoever wrote Access for having conditional formatting over-writing the enabled property
 
M

Mike375

Guest
He doesn't want to be able to select it, its in the background, selecting it spoils the look of things!!!, and he wants conditional formatting. Perhaps the full story in words of one syllable would help us, me anyway, understand whats going on and why.

Brian

Brian,

Know that, but we were just sorting out why he could select it with Enable No

Perhaps the solution is to overlay the field with a label that has background set as transparent....Just tried that and it is fine. I needed a full stop in the label but fixed the font colour
 

Brianwarnock

Retired
Local time
Today, 00:10
Joined
Jun 2, 2003
Messages
12,701
I know what we were asked, but I wanted the bigger picture, ie what was he trying to achieve, so that we could explore other options, but he's happy(ish) now so over and out

Brian
 

missinglinq

AWF VIP
Local time
Yesterday, 19:10
Joined
Jun 20, 2003
Messages
6,423
I just got back to this and I think I see the problem, or actually, I think you see the problem. A little known part of the Conditional Format is the CF to Enable a control. It's the last icon in the row.

B I U PaintBucket A and then a tiny command button looking thing. This is the Enable button, and the Default is Enable.

If you have Conditional Formatting on your textbox

and that condition is met

and you have left the Enable button set to Default

your previously disabled textbox will now be Enabled when the condition is met!

Hopefully setting this to Disable for the Conditional Formatting will solve your problem.

Linq
 

Darth Vodka

Registered User.
Local time
Today, 00:10
Joined
Sep 25, 2007
Messages
344
I just got back to this and I think I see the problem, or actually, I think you see the problem. A little known part of the Conditional Format is the CF to Enable a control. It's the last icon in the row

eureka!

that's it

dammit, i looked at that and thought it meant "disable the conditional format"

instead of "don't enable the control if conditional formatting is on it"

:confused:

it greys the format as well, as though it IS disabled, it's mind bogglingly unobvious

:D


bravo, that was bugging the hell out of me
 

Users who are viewing this thread

Top Bottom