Is there any way one can change the size of the checkbox and be able to remove the square border around it? I merely need to show a check mark in bigger size and without any border. I tried changing the properties but no luck. Hopoe someone can help.
Unless I am mistaken, there is no way to change the checkbox size and border properties. I have read through many Access programming books and I distinctly remember at least one of them saying that if you needed to change the properties (ie size and look) of a check box, you would have to create them your self....Here has been my solution:
Create a text box and set the font size to that which you want. Place one x in this box (ie your check will now be an x but this is usually acceptable to everyone). Once you have it all right, name it something like txtChecked.
Copy this text box and remove the x. Name this box txtUnchecked.
In the OnClick property of txtChecked, put the following:
Me![txtChecked].Visible = False
Me![txtUnchecked].Visible = True
In the OnClick for txtUnchecked, simply change the trues and falses around.
The last piece of the puzzle is that you have to check which box is visible whenever you need to use this....
Seems like a lot of work, but once you have the first one done, it comes along pretty easily. I have an example database with this inn it if you like....just send an email to the address in my profile and I will forward it to you. Good luck and let me know if I can help anymore. It's not important that someone else can do in one step what it took you ten to do...the important thing is that you found a solution.
Robert L. Johnson III, A+, Network+, MCP
Access Developer/Programmer
Sorry, I should have indicated that I am creating these checkboxes in a report and that might be the reason for not seeing the On Click propetry. I am trying to show in my report all those records which have been updated in a given week for user's convenience. I created a yes/no flag to achieve this. But if this solution is not applicable for logical fields in reports, I can change the field to something different.
Make sure the field in on the report, but is hidden. Make the checkboxes similar to what I already described. Set the Visible property of box the boxes to no. Then in the OnFormat event of the Details section use the following:
If Me![name of yes/no field] = True Then
Me![txtChecked].Visible = True
Me![txtUnchecked].Visible = False
ElseIf Me![name of yes/no field] = False Then
Me![txtChecked].Visible = False
Me![txtUnchecked].Visible = True
End If
This will square you away. Again, I can send you an example if you let. Just let me know. It's not important that someone else can do in one step what it took you ten to do...the important thing is that you found a solution.
Robert L. Johnson III, A+, Network+, MCP
Access Developer/Programmer
Another approach, if your form has sufficient space is to use an option group with the values True/False, Yes/No.
When you create the option group, set the value of the true option to -1 and the value of the false option to 0.
Bind the option group to your check box. When the user clicks on True the box will be checked; if the user clicks on False, the box will be unchecked.
On reports, if they are based on queries, you can set the display of the check box to text. Open the properties for the query (making sure the check box field is selected); on the lookup tab set the Display Control to Text Box; on the General Tab, set the Format to your choice of: Yes/No, True/False, On/Off.
Alternatively, you could use an immediate if (IIF) to test the value of the check box and create your own text display.
Personally, I hate check boxes on forms and reports. The are seldom intuitively obvious to the user. Using option groups on the forms and text displays on the reports is, to me, a more elegant approach.
Hope that helps. Larry De Laruelle
ldelaruelle@familychildrenscenter.org
Thank you for the feedback that heped a lot. I have a slightly different issue now. If you are using the default check boxes and choose to 'analyze the report' with Excel (an option you have in print preview screen), the whole report is transformed into spreadsheet or MS word document but for some strange reasons, check boxes don't get transferred into either of these format. Is there someting pereventing this to happen or is it a default feature of MS Access.Using the solution provided by Robert, I can get the check box across but not the value. But personally I would like to to have the ability to transfer my check boxes across without any manipulation.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.