﻿<?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?)  » Save Changes on Exit Problem</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 03:13:28 GMT</lastBuildDate><ttl>20</ttl><item><title>Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17959.aspx</link><description>I am having a problem with the Save Changes dialog.&amp;nbsp; The dialog box appears when attempting to close a form when I have not modified or added any records.&amp;nbsp; If I just open the form and close it, the dialog does not appear.&amp;nbsp; If I navigate to another record and attempt to close the form, the "Do You want to save changes?" dialog appears :crazy:! This form has a one-to-many business object relationship (4 child business objects).&amp;nbsp; Another odd thing is if I don't preload the child bo's when the form initializes, navigate to another parent bo record and attempt to close the form, the dialog does not appear.&amp;nbsp; Am I missing a setting somewhere?&amp;nbsp; Any help would be appreciated!&amp;nbsp; Thanks!&lt;/P&gt;&lt;P&gt;Doug</description><pubDate>Tue, 22 Jul 2008 08:53:53 GMT</pubDate><dc:creator>Douglas Riley</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17998.aspx</link><description>Glad you got it going :)</description><pubDate>Tue, 22 Jul 2008 08:53:53 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17972.aspx</link><description>[quote][b]Douglas Riley (07/21/2008)[/b][hr]Got it!&amp;nbsp; Added the IsDirtyChanged event to each BO and the guilty party appeared immediately.[/quote]&lt;P&gt;And what was causig the problem....?</description><pubDate>Mon, 21 Jul 2008 17:49:49 GMT</pubDate><dc:creator>Edhy Rijo</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17968.aspx</link><description>Cool! :D</description><pubDate>Mon, 21 Jul 2008 15:53:43 GMT</pubDate><dc:creator>Greg McGuffey</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17967.aspx</link><description>Got it!&amp;nbsp; Added the IsDirtyChanged event to each BO and the guilty party appeared immediately.&amp;nbsp; Again, thank you all!</description><pubDate>Mon, 21 Jul 2008 15:35:08 GMT</pubDate><dc:creator>Douglas Riley</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17966.aspx</link><description>Thank you all for the replies!&amp;nbsp; I will give this a shot and see what happens.&amp;nbsp; Thank you all!</description><pubDate>Mon, 21 Jul 2008 15:28:17 GMT</pubDate><dc:creator>Douglas Riley</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17963.aspx</link><description>Hi Douglas,&lt;/P&gt;&lt;P&gt;Also, check if you have any custom field property or a function/method that may be updating one of your BO's field and then becoming dirty as Trent and Greg suggested.</description><pubDate>Mon, 21 Jul 2008 15:01:20 GMT</pubDate><dc:creator>Edhy Rijo</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17961.aspx</link><description>I've had this happen several times.  Thus far it has always been something I've done :(&lt;br&gt;
&lt;br&gt;
The trick it to handle the IsDirtyChanged (something like that) event of the BO(s)...just put a break point there.  Open the form, navigate, close it...at some point this event will fire. Look at the call stack as see were you're inadvertently causing the BO to be dirty.  &lt;br&gt;
&lt;br&gt;
Hope that helps!</description><pubDate>Mon, 21 Jul 2008 14:47:39 GMT</pubDate><dc:creator>Greg McGuffey</dc:creator></item><item><title>RE: Save Changes on Exit Problem</title><link>http://forum.strataframe.net/FindPost17960.aspx</link><description>Well, the good news is that the only way that dialog will appear (if you are allowing it to show) is if one of the BOs on the form is dirty.&amp;nbsp; So you will want to look at your code and see which BO is becoming dirty.&lt;/P&gt;&lt;P&gt;When the form is closing, it will enumerate through the Businessobjects and collection and check if any of the Bos are dirty...if so, the form will come up.&lt;/P&gt;&lt;P&gt;So you will want to handle the IsDirtyChanged event of the BOs, set a break point on the set of a BO property, or something that will help you diagnose the problem.&amp;nbsp; So the first thing to figure out is which BO and field property is becoming dirty then you can work from there.</description><pubDate>Mon, 21 Jul 2008 14:45:41 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item></channel></rss>