StrataFrame Forum

Custom Properties BrowseDialog Search

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

By Guillermo Vilas - 11/5/2008

Hi, I´m facing with the problem that I have set a custom property field for the inventory table named ItemCode (String) that is populated with the ItemCode field in the Items Table to get item info clean.



I added this field as a searchable field in the BrowseDialog but because the BO needs to be filled before the custom property is actually returned I´m getting a KeyNotFoundException because the custom field does not belong to the Collection Dictionary.



Is there a workaround to get this working or I´ll just have to remove this search field.



Thanks for your help guys in advance Smile
By Ivan George Borges - 11/5/2008

Hi Guillermo.

You cannot use a custom property as a search field because the search fields are directly translated back to the query that is executed on SQL Server.  So, if the column does not exist on SQL Server, the BorwseDialog cannot use the field as a search field.

One way to accomplish this would be to create a view with all the fields you will need as search fileds and use the BrowseDialog on the view. If you decide for this, here is a post to get you started: http://forum.strataframe.net/FindPost20493.aspx

By Guillermo Vilas - 11/5/2008

Thanks Ivan I´ll look at that post.