﻿<?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 » WinForms (How do I?)  » BOTranslation from component to childForm</title><generator>InstantForum 2017-1 Final</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>StrataFrame Forum</webMaster><lastBuildDate>Tue, 09 Jun 2026 02:18:51 GMT</lastBuildDate><ttl>20</ttl><item><title>BOTranslation from component to childForm</title><link>http://forum.strataframe.net/FindPost10504.aspx</link><description>Hi,&lt;br&gt;
In my lookedit_ButtonClicked event, I need to launch childform. My BO is created in this event, but [b]not[/b] dropped on form.&lt;br&gt;
How could I "translate" my BO to childform?&lt;br&gt;
&lt;br&gt;
Thank you</description><pubDate>Sun, 22 Jul 2007 21:00:55 GMT</pubDate><dc:creator>Chan</dc:creator></item><item><title>RE: BOTranslation from component to childForm</title><link>http://forum.strataframe.net/FindPost10507.aspx</link><description>You have three options, first, just pass the craeted BO over as a parameter to the child form.&amp;nbsp;&amp;nbsp; Second, manually add the item to the translation collection.&lt;/P&gt;&lt;P&gt;[codesnippet]&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; '-- Decalre this as a private on&amp;nbsp;Form1&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Private _MyBO As MySourceBO&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;BR&gt;&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; '-- Manually add the translation&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Dim loItem As New MicroFour.StrataFrame.UI.Windows.Forms.BusinessObjectTranslationItem()&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; loItem.SourceBusinessObject = "Form1._MyBO"&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; loItem.DestinationBusinessObject = "Form2._DestBO"&lt;BR&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; Me.ChildFormDialog1.BusinessObjectTranslations.Add(loItem)[/codesnippet]&lt;/P&gt;&lt;P&gt;Last option, manually translate the BOs yourself by calling the translater directly.&lt;/P&gt;&lt;P&gt;[codesnippet]MicroFour.StrataFrame.UI.Windows.Forms.BusinessObjectTranslator.TranslateBusinessObjects(SourceBO,DestBO,"DestBOInstanceName",Form1,Form2)[/codesnippet]</description><pubDate>Sun, 22 Jul 2007 21:00:55 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item></channel></rss>