﻿<?xml version="1.0" encoding="UTF-8"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum » StrataFrame Application Framework - V1 » Issues  » ComboBox, using AutoSelectFirstItemOnValidateForNoSelection, errors after second invalid entry</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Sat, 16 May 2026 23:00:24 GMT</lastBuildDate><ttl>20</ttl><item><title>ComboBox, using AutoSelectFirstItemOnValidateForNoSelection, errors after second invalid entry</title><link>http://forum.strataframe.net/FindPost32463.aspx</link><description>Hello SF Devs,&amp;nbsp;&lt;br/&gt;&lt;br/&gt;&lt;div&gt;Can you confirm this bug that I am experiencing?&amp;nbsp;&lt;br/&gt;&lt;br/&gt;&lt;div&gt;I have an SF ComboBox bound to a business object integer property. It is setup to be an AutoComplete ComboBox (Mode: SuggestAppend) and the&amp;nbsp;&lt;strong&gt;AutoSelectFirstItemOnValidateForNoSelection &lt;/strong&gt;is set to true.&amp;nbsp;&lt;div&gt;It works fine until the user types a string that does not match any option in the dropdown and tabs off the control twice in a row.&lt;div&gt;At this point it will throw the following error:&amp;nbsp;&lt;br/&gt;&lt;br/&gt;&lt;div&gt;Specified cast is not valid.&lt;div&gt;&lt;div&gt;&amp;nbsp; &amp;nbsp;at GKGLibExamples.BusinessObjects.ItemsBO.FieldDescriptor.SetValue(Object component, Object value) in C:\Users\gberrio\Documents\Visual Studio 2008\Projects\GKGLib\GKGLibExamples\BusinessObjects\ItemsBO.Designer.cs:line 1767&lt;div&gt;&amp;nbsp; &amp;nbsp;at System.Windows.Forms.BindToObject.SetValue(Object value)&lt;div&gt;&amp;nbsp; &amp;nbsp;at System.Windows.Forms.Binding.PullData(Boolean reformat, Boolean force)&lt;br/&gt;&lt;br/&gt;&lt;div&gt;The value it is trying to set the property to is DBNull.&lt;br/&gt;&lt;br/&gt;&lt;div&gt;Reproduction Steps:&lt;div&gt;&amp;nbsp; &amp;nbsp; - select the combobox&lt;div&gt;&amp;nbsp; &amp;nbsp; - enter a string that does not return an auto suggest option&lt;div&gt;&amp;nbsp; &amp;nbsp; - tab off the control&lt;div&gt;&amp;nbsp; &amp;nbsp; - select the combobox again&lt;div&gt;&amp;nbsp; &amp;nbsp; - enter a string that does not&amp;nbsp;return an auto suggest option&lt;div&gt;&amp;nbsp; &amp;nbsp; - ! ERROR !&lt;br/&gt;&lt;br/&gt;&lt;div&gt;&lt;img src="http://forum.strataframe.net/Uploads/Images/c7e7d89c-a85c-4544-81e7-ca06.PNG" alt="http://forum.strataframe.net/Uploads/Images/c7e7d89c-a85c-4544-81e7-ca06.PNG" /&gt;&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;&lt;br/&gt;</description><pubDate>Mon, 24 Feb 2014 16:15:16 GMT</pubDate><dc:creator>Govinda Berrio</dc:creator></item></channel></rss>