+ Reply to Thread
Results 1 to 6 of 6

Why Undo commandbutton is Cleared ?

  1. #1
    halimnurikhwan@yahoo.com
    Guest

    Why Undo commandbutton is Cleared ?

    Hi all,

    I have a problem if I use :

    '>>>>>>>>>>>>>
    sub cariorfind()
    set findx = activesheet.cells.find(What:="words")
    if not findx is nothing then msgbox findx.address
    end sub
    '>>>>>>>>>>>>>

    the undo command lists is cleared after the procedure above,
    so I can't undo my previous action...
    anyone please help me to answer it ...!

    Thank you very much..
    regds,
    Halim


  2. #2
    Duncan
    Guest

    Re: Why Undo commandbutton is Cleared ?

    Halim,


    As far as I know, you cannot undo anything done via VBA code.

    I may be wrong, but I have noticed this and it has never let me undo
    anything I have done through code.

    is there a specific action you wish to undo as you may be able to
    achieve it with your code, like storing the previous settings and then
    restoring after your code?

    Duncan


    halimnurikh...@yahoo.com wrote:

    > Hi all,
    >
    > I have a problem if I use :
    >
    > '>>>>>>>>>>>>>
    > sub cariorfind()
    > set findx = activesheet.cells.find(What:="words")
    > if not findx is nothing then msgbox findx.address
    > end sub
    > '>>>>>>>>>>>>>
    >
    > the undo command lists is cleared after the procedure above,
    > so I can't undo my previous action...
    > anyone please help me to answer it ...!
    >
    > Thank you very much..
    > regds,
    > Halim



  3. #3
    Norman Jones
    Guest

    Re: Why Undo commandbutton is Cleared ?

    Hi Halim,

    See John Walkenbach's comments and suggestions at:

    http://www.j-walk.com/ss/excel/tips/tip23.htm


    ---
    Regards,
    Norman


    <halimnurikhwan@yahoo.com> wrote in message
    news:1153209997.558836.191510@s13g2000cwa.googlegroups.com...
    > Hi all,
    >
    > I have a problem if I use :
    >
    > '>>>>>>>>>>>>>
    > sub cariorfind()
    > set findx = activesheet.cells.find(What:="words")
    > if not findx is nothing then msgbox findx.address
    > end sub
    > '>>>>>>>>>>>>>
    >
    > the undo command lists is cleared after the procedure above,
    > so I can't undo my previous action...
    > anyone please help me to answer it ...!
    >
    > Thank you very much..
    > regds,
    > Halim
    >




  4. #4
    halimnurikhwan@yahoo.com
    Guest

    Re: Why Undo commandbutton is Cleared ?

    Hi Duncan,

    As far as I know that's not always but often,
    and I think that code not change value in cells or
    something that react undo lists...

    rgds,
    halim


    Duncan menuliskan:
    > Halim,
    >
    >
    > As far as I know, you cannot undo anything done via VBA code.
    >
    > I may be wrong, but I have noticed this and it has never let me undo
    > anything I have done through code.
    >
    > is there a specific action you wish to undo as you may be able to
    > achieve it with your code, like storing the previous settings and then
    > restoring after your code?
    >
    > Duncan



  5. #5
    halimnurikhwan@yahoo.com
    Guest

    Re: Why Undo commandbutton is Cleared ?

    Hi Norman,
    I've tried that way... but it seems only undo once ...
    How to add the existing undo action lists ... ?
    thanks,

    hAlim



    Norman Jones menuliskan:
    > Hi Halim,
    >
    > See John Walkenbach's comments and suggestions at:
    >
    > http://www.j-walk.com/ss/excel/tips/tip23.htm
    >
    >
    > ---
    > Regards,
    > Norman
    >
    >
    > <halimnurikhwan@yahoo.com> wrote in message
    > news:1153209997.558836.191510@s13g2000cwa.googlegroups.com...
    > > Hi all,
    > >
    > > I have a problem if I use :
    > >
    > > '>>>>>>>>>>>>>
    > > sub cariorfind()
    > > set findx = activesheet.cells.find(What:="words")
    > > if not findx is nothing then msgbox findx.address
    > > end sub
    > > '>>>>>>>>>>>>>
    > >
    > > the undo command lists is cleared after the procedure above,
    > > so I can't undo my previous action...
    > > anyone please help me to answer it ...!
    > >
    > > Thank you very much..
    > > regds,
    > > Halim
    > >



  6. #6
    Norman Jones
    Guest

    Re: Why Undo commandbutton is Cleared ?

    Hi Halim,

    Many macro instructions will destroy Excel's undo list. There is no way to
    restore the undo list. If you wish to provide an undo facility for your
    macro, you will need to add code to provide your own undo functionality.

    In the suggested link, John Walkenbach demonstrates a simple undo strategy.
    In his commercially available Power Utility Pak utility, John Walkenbach
    provides more complex examples.

    In short, however, if you require an undo functionality in your VBA
    routines, invariably the onus will be on you to add code to provide such
    functionality.



    ---
    Regards,
    Norman



    <halimnurikhwan@yahoo.com> wrote in message
    news:1153211349.565310.58230@h48g2000cwc.googlegroups.com...
    > Hi Norman,
    > I've tried that way... but it seems only undo once ...
    > How to add the existing undo action lists ... ?
    > thanks,
    >
    > hAlim




+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1