main logo
Subject: Re: do you want to save
Author: Jose Constant
Posted: 2001/09/18 10:09:57
 
View Entire Thread
New Search


<i><font color="#663300">I just know I am going to hate myself when this is answered.
I have been with codebook for years now and can't believe I don't know the answer to this question. I looked back through the threads but they are only accessable to mid 2000. I know this has been dealt with before.
All my development projects to date have used forms without controlboxes so I make intrinsic calls to SAVE and CANCEL with form buttons.
I am now playing around using the toolbar globally to control forms.
The problem:
Clicking on the Close control on the form or Close in the toolbar closes open forms ok but even if no changes have been made, Ischanged() is returning true. So I get the dreaded "Do you want to save your changes first" box.
Something is happening in the memento class I guess but I can't see what. I have tried different bufferring options to no effect.
Can someone point me in the right direction.
signed
embarassed! </font></i>

When this sort of thing happens, it always relates to the pointer being moved. So, when the memento does its thing he is a bit confused... Check for what moved the record pointer and you'll have the solution.

In some cases I may need to refresh the memento. So I added a method which acts as a public interface to it, since SetMemento() is a protected method. It's called RecordPointerMoved() and simply does a THIS.SetMemento(). Do not know about the current framework, tough. It might be implemented.

Jose

Jose Constant
Constant Software Systems
Belgium
<a href=http://www.constant.be/css target=_blank>Jose's Web Site</a>
 
©2001 Jose Constant
<-- Prior Message New Search Next Message -->