StrataFrame Forum

Boolean Browse Dialog Search Item

http://forum.strataframe.net/Topic10247.aspx

By Paul Chase - 7/13/2007

If a search item field is boolean would it be possible to have the search field use a checkbox control rather than a masked textbox?

P

By Trent L. Taylor - 7/13/2007

Actually, you are better off creating an enum with a True/False value.  The BrowseDialog allows you to specify an Enum value for a Boolean which will translate over the a boolean when performing the query.  This generally makes more sense to the end user allowing them to choose Yes/No or True/False or something of that nature.
By Paul Chase - 7/13/2007

That makes sense I'll try it and see how they like it. 
By Bill Cunnien - 6/19/2008

I cannot get this to work.  I have a boolean field in my PartsBO.  It is tied to a custom enumeration called StandardBoolean (true = 1, false = 0).  The underlying SQL Server field is a bit datatype.  In the search fields, I have added the boolean field and assigned the enum type in the combo-enum tab.  I also want all queries to start from a 'false' position, so I entered "0" into the Initial Search Value on the General tab.  Testing always results in "String was not recognized as a valid Boolean."  This is driving me Crazy 

What silly step am I missing here?

Thanks,
Bill

By Trent L. Taylor - 6/19/2008

Be sure to load the latest 1.6.6 beta.  I made a change to ensure that this message doesn't come up.  I know it works (on the latest build) because I did this just the other day. Wink
By Bill Cunnien - 6/19/2008

No matter what I stick in for the initial value, I always get this:

String was not recognized as a valid Boolean.

   at System.Boolean.Parse(String value)
   at MicroFour.StrataFrame.UI.Windows.Forms.BrowseDialogwindow.BuildWhereElement(SearchFieldItem SearchField)
   at MicroFour.StrataFrame.UI.Windows.Forms.BrowseDialogwindow.BuildSearchWhereClause()
   at MicroFour.StrataFrame.UI.Windows.Forms.BrowseDialogwindow.ExecuteSearch()
   at MicroFour.StrataFrame.UI.Windows.Forms.BrowseDialogwindow.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.ContainerControl.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.ContainerControl.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.ContainerControl.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.ContainerControl.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.TextBoxBase.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.MaskedTextBox.ProcessCmdKey(Message& msg, Keys keyData)
   at System.Windows.Forms.Control.PreProcessMessage(Message& msg)
   at System.Windows.Forms.Control.PreProcessControlMessageInternal(Control target, Message& msg)
   at System.Windows.Forms.Application.ThreadContext.PreTranslateMessage(MSG& msg)

Btw, if anyone has seen my patience anywhere, please let me know...I've lost mine.  Thanks.

Wink
Bill

By Trent L. Taylor - 6/19/2008

Did you read my previous post?
By Bill Cunnien - 6/19/2008

Just missed your post.  Sorry.

Installing an update sounds like a really simple solution; however, there is more to it than simply downloading and installing.  There are third-party controls to worry about, my country's 500th anniversary to plan, my wedding to arrange, my wife to murder, and Gilder to frame for it.  I'm swamped!

Seriously, I'll see if I can get that installed this afternoon.  Thanks a lot!
Bill

By Bill Cunnien - 6/19/2008

When will the source code for 1.6.6 (1.6.5.2) be available?  Only 1.6.5.1 is available under my account.  Thanks.
By Trent L. Taylor - 6/19/2008

It should be pretty much up to date.  I may have just not changed the version in the downloads area.