Jeff Johnson wrote on 2013-12-11: 
>  I guess I did not make myself clear.  I have an import object.  It has
>  no interface and is based on a custom class.  It opens tables, does
>  queries on sql server tables and then populates the tables and runs as a
>  server so to speak. It does the import every 10 minutes.  I have been
>  using this class for over 10 years and I am modifying a few things.  In
>  my modifications I have done something wrong and I get an error.  I want
>  to stop the process completely at that point, but can't figure out how
>  to do it.  Does destroy() do that?  I am running it in a top level
>  form.  Maybe clear events will work?
> 
> 
>  Jeff
>  

Jeff,

A Try/Catch will work.

When I was in VFP 6, I used the Error handler to return to a launch method.
The class had a structure something like this:
    Procdedure customprocess
        This.customprocess_code()
    Endproc
    Procedure customprocess_code
        *-- the meat of my work
    Endproc
    Procedure Error
        Lparameters nError, cMethod, nLine
        *-- handle the error
        Return to customprocess && This might be able to take
this.customprocess
    Endproc 


Tracy Pearson
PowerChurch Software


_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: 
http://leafe.com/archives/byMID/profox/000401cef6c4$4b5493a0$e1fdbae0$@powerchurch.com
** All postings, unless explicitly stated otherwise, are the opinions of the 
author, and do not constitute legal or medical advice. This statement is added 
to the messages for those lawyers who are too stupid to see the obvious.

Reply via email to