Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Conditional format or similar on form checkbox

Posted on 2014-01-28
11
Medium Priority
?
405 Views
Last Modified: 2014-01-29
On a small form I've used conditional formatting to make some empty rows between the choices - but how can I hide the check boxes on the "empty" rows ? Database running on Access 2003/2010.

Choice list
0
Comment
Question by:Bojerne
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 3
  • 3
11 Comments
 
LVL 61

Expert Comment

by:mbizup
ID: 39814612
You can't format a checkbox, and you can't set it's visible property to false with conditional formatting.

A possible workaround is to use a textbox to simulate a checkbox, and use conditional formatting to hide/show that textbox instead.
0
 
LVL 14

Expert Comment

by:Bill Ross
ID: 39814912
Hi,

Another method is to create an empty text box with the background and border the same color as the form background.  Place the textbox over the CheckBox and use conditional formatting to make it visible or not, essentially hiding the CheckBox behind it.

Regards,

Bill
0
 
LVL 1

Author Comment

by:Bojerne
ID: 39815233
You both suggest to show/hide a textbox - but it's not possible to show/hide a textbox - only to activate/inactivate the textbox, which will not look nice :) Otherwise a really good suggestion.
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 61

Expert Comment

by:mbizup
ID: 39815412
Understood - as you noted there is no option for 'visibility' in conditional formatting.

Our explanations might not have been clear, but the idea is to toggle text and/or background colors to disguise the textbox instead.  ie: if you have a borderless textbox whose font and backcolor are the same as the detail section, then that textbox is effectively not visible.
0
 
LVL 1

Author Comment

by:Bojerne
ID: 39815424
I can understand that ie a textbox with white text and backgound can hide the underlying checkbox - but I don't see how I the can make the checkbox visible ? And as it's unfortunately not possible to conditional format the border, the textbox cannot be made to look like a checkbox :) ?
0
 
LVL 14

Expert Comment

by:Bill Ross
ID: 39815884
Hi,

Make the border transparent.  All you want to do is cover the checkbox.

Regards,

Bill
0
 
LVL 1

Author Comment

by:Bojerne
ID: 39816954
Hi Bill

I'm probably a bit slow here but I can understand that ie a textbox with white text and backgound can hide the underlying checkbox - but I don't see how I the can make the checkbox visible Again when I can't hide the textbox ?
Thanks
Mike
0
 
LVL 14

Expert Comment

by:Bill Ross
ID: 39817738
Hi Mike,

Create a text box with a transparent border and background.  
Please it over the checkbox - it will be invisible and the checkbox will show.
Use conditional formatting to make the background of the text box the same color as forms detail area background when the checkbox needs to be hidden.

Post your db and I'll get you started.

Thanks,

Bill
0
 
LVL 1

Author Comment

by:Bojerne
ID: 39817829
You can't do that - the backgruond of the textbox, will change from Transparent to Normal (ie solid) when you start using conditional formatting.
0
 
LVL 61

Accepted Solution

by:
mbizup earned 2000 total points
ID: 39818009
This is the idea I was trying to describe, using a textbox to simulate a checkbox.  Try frmTest in the sample db.

That said.... What you are trying to do is ultimately and simply *not possible* in Access, so you will have to find a livable workaround (which as workarounds go, is unlikely to look or behave 'exactly' as you want it to).

Further, the purpose of conditional formatting in general is to make certain values stand out.  Hiding entire records just strikes me as contrary to that purpose.  So I'm curious about things like:

1.  How many rows of data are we talking about?
2.  What are the rules involved in hiding specific records?
3.  What is the overall reason for hiding these records?

There may be a better approach than conditional formatting to handling these "gaps" in your data presentation.
HideCheckBox.accdb
0
 
LVL 1

Author Comment

by:Bojerne
ID: 39818033
Hi MBizup
Thank you for the example. I suspected it wasn't possible to do what I was wishing for - but wanted to be sure. Your example is a good alternative :)
0

Featured Post

Visualize your virtual and backup environments

Create well-organized and polished visualizations of your virtual and backup environments when planning VMware vSphere, Microsoft Hyper-V or Veeam deployments. It helps you to gain better visibility and valuable business insights.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Part II of this series, I will discuss how to identify all open instances of Excel and enumerate the workbooks, spreadsheets, and named ranges within each of those instances.
This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
In Microsoft Access, learn how to “cascade” or have the displayed data of one combo control depend upon what’s entered in another. Base the dependent combo on a query for its row source: Add a reference to the first combo on the form as criteria i…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…

604 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question