benwiggy Posted November 4, 2011 Posted November 4, 2011 I want to add a field to my layout that is a checkbox, which I can tick or un-tick to represent a simple Boolean Yes or No. Do I have to create a Value List of One Item? If I create a Value List of "Compiled?", then that is value that gets put into the field, rather than a 1 or 0 or Yes or No? Is there an easier way, or am I going to have to write a script to sort out this seemingly simple piece of interface? Many thanks
comment Posted November 4, 2011 Posted November 4, 2011 Create a value list of one item, with "1" being that item. Make the actual field narrow to hide the value. Another option is to define the field as a button doing: Set Field [ YourTable::Compiled ; not YourTable::Compiled ] and format the field as Boolean. 1
benwiggy Posted November 4, 2011 Author Posted November 4, 2011 I like the sound of the second option. That seems to work: though I need some sort of indicator to show the two states on he button. I'll work on it. Thanks.
comment Posted November 4, 2011 Posted November 4, 2011 I need some sort of indicator to show the two states on he button. How about the field itself?
benwiggy Posted November 5, 2011 Author Posted November 5, 2011 I've used Conditional Formatting to make the Button dark when the value is 1 and light when the value is 0. It's not an actual tick box, but it'll do.
Prob Posted November 8, 2011 Posted November 8, 2011 An easy way to switch a boolean field is: Abs ( Sign ( Table::Field - 1 ) )
LaRetta Posted November 8, 2011 Posted November 8, 2011 An easy way to switch a boolean field is: Abs ( Sign ( Table::Field - 1 ) ) Or as Comment suggested ... not Table::Field
LaRetta Posted November 8, 2011 Posted November 8, 2011 BTW, I forgot to mention ... as Michael suggests, you can use the field itself to make the indicators. Put another copy of your field on the layout. Turn off entry to the field. Set the font to webdings on the field. Go to Inspector, Data tab and below, specify Boolean on number. Type a 5 in the non-zero for up indicator and 6 in the zero for down indicator.
Recommended Posts
This topic is 4764 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now