Follow the changes

pdabasic

Active Member
Licensed User
I try to use a "back/forward" button and a "alert when I have unsaved data"...

I think I register the datas in a table.
First col contains the name of edited control and the others contain the values
and when I click "back" it looks for the changes and replace the values...

I think this way is not the best solution... :confused:

How do you usually do this???
:sign0085:
 

klaus

Expert
Licensed User
Longtime User
You must give some more information on what you are already doing and want you want to add.
Where do your data come from?
Where and how are they changed?
Could you post the code you already have so we could look at it to better understand and give you concrete advices?

Best regards.
 

pdabasic

Active Member
Licensed User
A Stack can be useful for implementing such functionality as it is a Last In First Out (LIFO) sructure.

An Arraylist can also be used and can actually be a better solution as it allows you to limit its size by removing "old" items from the beginning.

Can you give me a little example with some "TextBox" Control, because I don't understand you exactly...
 

pdabasic

Active Member
Licensed User
Are you trying to create a text editing application?
What are you considering as a valid event which should be stored? Each keystroke?

I write a symple database app. and I collect the informations with textboxes and listboxes. I don't need to follow all keystrokes, just need the hole value what i can store with a "textchanged event with door libray" and "selection changed event". Only this changes I would like to follow!
 

mjcoon

Well-Known Member
Licensed User
... I don't need to follow all keystrokes, just need the hole value what i can store ...

If you only wish to record the completed text that the user has entered, would it be better to have a separate button or similar way for the user to indicate that he has finished text entry?

Mike.
 

pdabasic

Active Member
Licensed User
If you only wish to record the completed text that the user has entered, would it be better to have a separate button or similar way for the user to indicate that he has finished text entry?

Mike.


The problem is not the storing.
I would like to write an "undo" command.
When I type a value in a textbox or choose a value in a list and I make a fault I would like to use a button which can set the textbox or combobox value to the previous value and if i click again it sets the previous previos and so on.
 

pdabasic

Active Member
Licensed User
I try to find the way what you usually use to the storing the changes and the starting value and the controller index where I managed the changes!
I need the fastest solution!

Here Is a simple Example where I do something I need to use "Undo" or "Redo" Feature!

If I click the Undo, it sets all controls and variables the previous state.
 

Attachments

  • Follow.sbp
    1.7 KB · Views: 181
Top