Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsFormsForms ProgrammingQueriesModules / DAO / VBAReports / PrintingMacrosDatabase DesignSecurityConversionImporting / LinkingSQL Server / ADPMultiuser / NetworkingReplicationSetup / ConfigurationDeveloper ToolkitsActiveX ControlsNew UsersGeneral 1General 2
Access DirectoryToolsTutorialsUser Groups
Related Topics
SQL ServerOther DB ProductsMS OfficeMore Topics ...

MS Access Forum / Forms Programming / December 2005

Tip: Looking for answers? Try searching our database.

yes/No -1,0

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Terry - 31 Dec 2005 16:57 GMT
I have a table with a yes/no field and on a form I want to search by that
field.  If I set the textbox data to value and put yes, No the textbox
displays Yes or No as it should but the search fails.  If I put -1, 0 as the
values,  the search works as it should.  Isn't there an easy way to make the
No get evaluated as 0 and so forth?
Allen Browne - 31 Dec 2005 17:41 GMT
If this is an unbound text box, set its Format property to Yes/No.

Signature

Allen Browne - Microsoft MVP.  Perth, Western Australia.
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

>I have a table with a yes/no field and on a form I want to search by that
> field.  If I set the textbox data to value and put yes, No the textbox
[quoted text clipped - 3 lines]
> the
> No get evaluated as 0 and so forth?
John Vinson - 31 Dec 2005 20:56 GMT
>I have a table with a yes/no field and on a form I want to search by that
>field.  If I set the textbox data to value and put yes, No the textbox
>displays Yes or No as it should but the search fails.  If I put -1, 0 as the
>values,  the search works as it should.  Isn't there an easy way to make the
>No get evaluated as 0 and so forth?

Several. One would be to use a Combo Box with a rowsourcetype Value
List, RowSource -1;Yes;0;No , ColumnCount 2, ColumnWidths 0,0.25.
Another would be to use an Option Group control with two buttons,
values -1 and 0, labels Yes and No.

                 John W. Vinson[MVP]    
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.