Undo option

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • John

    Undo option

    Hi

    Is it possible to implement an application wide Undo facility, like that
    under the Edit menu?

    Thanks

    Regards


  • William Ryan

    #2
    Re: Undo option

    Depends where you are undoing from (Undoing changes you just commited to a
    database is more difficult than say undoing something you jsut typed). If
    you are doing it with controls, both the RichTextBox and TextBox controls
    have an undo method. But if you want more complex undoing, it'lll take code
    specific to the issue at hand.
    "John" <john@nospam.in fovis.co.uk> wrote in message
    news:e4QiLd72DH A.1752@tk2msftn gp13.phx.gbl...[color=blue]
    > Hi
    >
    > Is it possible to implement an application wide Undo facility, like that
    > under the Edit menu?
    >
    > Thanks
    >
    > Regards
    >
    >[/color]


    Comment

    • Cor

      #3
      Re: Undo option

      Hi John,

      In addition to Bill,

      Undoing i always reseting from the previous situation.
      If you want to undo from a not yet updated database, it is easy, you only
      have to reread it.

      If you want to do it in another not implemented situations (as Bill said)
      than you have to build your own stack schema with tempory situations.
      (and a clean up situation)

      I hope this helps

      Cor


      Comment

      • Jeremy Cowles

        #4
        Re: Undo option

        "John" <john@nospam.in fovis.co.uk> wrote in message
        news:e4QiLd72DH A.1752@tk2msftn gp13.phx.gbl...[color=blue]
        > Hi
        >
        > Is it possible to implement an application wide Undo facility, like that
        > under the Edit menu?[/color]

        In your favorite design pattern source, see the "Command" pattern. I
        recommend the book Design Patterns, or http://msdn.microsoft.com/patterns/

        HTH,
        Jeremy

        Comment

        • Tom Clement

          #5
          Re: Undo option

          "John" <john@nospam.in fovis.co.uk> wrote in message news:<e4QiLd72D HA.1752@tk2msft ngp13.phx.gbl>. ..[color=blue]
          > Hi
          >
          > Is it possible to implement an application wide Undo facility, like that
          > under the Edit menu?[/color]

          I just posted an article in CodeProject that might be of some help.
          It's in C#, but can be used without any modification.



          Hope this helps.
          Tom

          Comment

          Working...