﻿<?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?)  » Problems when Passing Business Object ByRef</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Wed, 20 May 2026 16:30:10 GMT</lastBuildDate><ttl>20</ttl><item><title>Problems when Passing Business Object ByRef</title><link>http://forum.strataframe.net/FindPost12147.aspx</link><description>I have two related business objects. I have some code to add records to both business objects and when I execute this code within a form, the code runs fine and the records are added properly.&lt;/P&gt;&lt;P&gt;I needed the ability to share this logic with other programs so I moved my logic to the parent business object class and pass the child business object ByRef.&amp;nbsp; When I execute the code, I get an error creating a new row on the child BO.&amp;nbsp; (System.IndexOutOfRangeException). Index 0 is either negative or above rows count.&lt;/P&gt;&lt;P&gt;It seems to execute the NewRow fine and it actually sets the Fk value correctly on the child record but as soon as I try to assign something to any other field it errors out.&lt;/P&gt;&lt;P&gt;Any Idea's??&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Tim</description><pubDate>Tue, 06 Nov 2007 10:09:11 GMT</pubDate><dc:creator>Tim Dol</dc:creator></item><item><title>RE: Problems when Passing Business Object ByRef</title><link>http://forum.strataframe.net/FindPost12492.aspx</link><description>Yes he did. Thanks.&lt;/P&gt;&lt;P&gt;TIm</description><pubDate>Tue, 06 Nov 2007 10:09:11 GMT</pubDate><dc:creator>Tim Dol</dc:creator></item><item><title>RE: Problems when Passing Business Object ByRef</title><link>http://forum.strataframe.net/FindPost12429.aspx</link><description>I think Trent emailed you back the option that states that the BeginLoadData() prevents the DefaultView from being updated and the business object uses that view extensively.</description><pubDate>Mon, 05 Nov 2007 10:20:53 GMT</pubDate><dc:creator>StrataFrame Team</dc:creator></item><item><title>RE: Problems when Passing Business Object ByRef</title><link>http://forum.strataframe.net/FindPost12366.aspx</link><description>We were finally able to recreate the problem in a test project.&amp;nbsp; I emailed you guys the test project so you can replicate the index error.&lt;/P&gt;&lt;P&gt;Tim</description><pubDate>Fri, 02 Nov 2007 08:43:48 GMT</pubDate><dc:creator>Tim Dol</dc:creator></item><item><title>RE: Problems when Passing Business Object ByRef</title><link>http://forum.strataframe.net/FindPost12298.aspx</link><description>Trent,&lt;/P&gt;&lt;P&gt;This same issue&amp;nbsp;has popped up in another piece of code. We tried building a sample application to replicate for you,&amp;nbsp;but of course it works fine in the sample code.&amp;nbsp; I sent you any email requesting a remote session so we can show you the problem. It's kind of holding us back from finishing an important&amp;nbsp;project so I would appreciate a few minutes of your time to show you the issue.&lt;/P&gt;&lt;P&gt;Thanks,&lt;BR&gt;Tim</description><pubDate>Wed, 31 Oct 2007 10:13:47 GMT</pubDate><dc:creator>Tim Dol</dc:creator></item><item><title>RE: Problems when Passing Business Object ByRef</title><link>http://forum.strataframe.net/FindPost12177.aspx</link><description>Hmmm....let us know if this pops back up :)</description><pubDate>Wed, 24 Oct 2007 22:07:18 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: Problems when Passing Business Object ByRef</title><link>http://forum.strataframe.net/FindPost12153.aspx</link><description>You can ignore this for now.&amp;nbsp; There were other strange things happening on this form so I created a new form and the problem disappeared. Not sure why, but I can now create new records in the business object without any errors.&lt;/P&gt;&lt;P&gt;Tim</description><pubDate>Tue, 23 Oct 2007 15:50:46 GMT</pubDate><dc:creator>Tim Dol</dc:creator></item></channel></rss>