Link to home
Create AccountLog in
Avatar of Patrick O'Dea
Patrick O'DeaFlag for Ireland

asked on

Access form very full - Make space by putting "heading in where field goes"

Hi,

Simple query but a bit tricky to explain.

I have a very squashed form and I need to add a new field "Car Color".

In order to save space, I would like to put the actual heading "Car Color" in feint grey IN the actual field.

Therefore when I type a value into the field , I will be typing OVER the heading "Car Color".

Is this clear?
Is this possible?
SOLUTION
Avatar of lee555J5
lee555J5
Flag of United States of America image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of mbizup
Try placing a label behind the text box and setting the Back Style property of the textbox to Transparent.
SOLUTION
Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Avatar of Patrick O'Dea

ASKER

Thanks mbizup,

Your workaround solution works reasonably well.
However, I had hope Access could do better?

But I guess that's it?  Unless anyone knows better??
Using the skinned cats theory, could you post a sample DB, or a hi-res screen shot of your form?  There might be other solutions.
What you're describing actually does not sound too different from simply using a default value for the textbox.  Have you ruled that out?
mbizup, is there something else to do? Once the textbox loses focus, both the label caption AND the textbox text is visible, overwriting each other. How do you stop that so only the textbox contents are visible?

Lee
That is a problem with this idea... I figured the author had considered that when mentioning using a light colored text.  But you could go a step further by controlling the visibility of the label with code in the After Update event of the textbox and in the Current event of the form:

Me.Labelname.visible = ("" & Me.textboxName <> "")

Open in new window

This gives the 'type over' effect you want, but not in light gray.
Put this in the Format property of the Text Box:

@;"<Car Color>"

 User generated image
Result:

User generated image
Yes indeed MX, that is very good.

Interesting suggestions from all folk.
I will leave call open for a short while but I think MX's solution may not be bettered.
ASKER CERTIFIED SOLUTION
Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account
Before typing (and no entry)

User generated image
After typing and exit

User generated image
Thanks all,

That great!