﻿<?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 » Business Objects and Data Access (How do I?)  » DataSourceKey error within User Control</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Fri, 26 Jun 2026 02:25:15 GMT</lastBuildDate><ttl>20</ttl><item><title>DataSourceKey error within User Control</title><link>http://forum.strataframe.net/FindPost7712.aspx</link><description>I have created a User Control that basically displays data on an&amp;nbsp;Infragistics Grid control using a BusinessBindingSource.&amp;nbsp;&amp;nbsp;I added a line of code to fill the business object.&lt;/P&gt;&lt;P&gt;When I drag this control onto a form I get an error. (See Attached Doc). I'm not sure if I'm doing something wrong as I can fill the same business object on a normal form without any problems.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Tim</description><pubDate>Mon, 26 Mar 2007 16:01:14 GMT</pubDate><dc:creator>Tim Dol</dc:creator></item><item><title>RE: DataSourceKey error within User Control</title><link>http://forum.strataframe.net/FindPost7718.aspx</link><description>Yes, you are not testing for design-time.&amp;nbsp; Your fill method is either in the New or the Load and since you are at design-time you do not have a connection string (or DAL) defined.&amp;nbsp; Be sure and use an event such as the Load rather than the New because the design-time indicator may not yet be set in some cases.&lt;/P&gt;&lt;P&gt;[codesnippet]If Not Me.DesignMode Then &lt;BR&gt;&amp;nbsp; '-- Fill your BO&lt;BR&gt;End If[/codesnippet]</description><pubDate>Mon, 26 Mar 2007 16:01:14 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item></channel></rss>