Strange database error when closing Livecode on Windows
Peter Haworth
pete at lcsql.com
Thu Jul 12 16:56:50 EDT 2012
Maybe. But it doesn't happen on Macs, only Windows (haven't tried Linux).
I hope Livecode doesn't do that on any platform since it's quite possible
that applications will want to do some db housekeeping when they are closed
and this would prevent them from doing it.
Pete
lcSQL Software <http://www.lcsql.com>
On Thu, Jul 12, 2012 at 1:10 PM, Bob Sneidar <bobs at twft.com> wrote:
> My guess would be that because LC closes all database connections itself
> when you quit, that LC has already closed the database connection when your
> script tries to do it again, with a now defunct database id.
>
> Bob
>
>
> On Jul 12, 2012, at 12:31 PM, Peter Haworth wrote:
>
> > I have a closeStack handler on card 1 of my main stack that calls
> > revCloseDatabase passing a global variable in as the database id. It
> > checks that the variable is an integer before calling revCloseDatabase
> just
> > in case the db wasn't opened.
> >
> > This ll works fine when I close the stack. However, if I exit Livecode
> on
> > Windows with the stack open, I get a runtime error message "revdberr,
> > invalid connection id" on the revCloseDatabase command. Thsi only
> happens
> > on Windows, not Mac… exactly the same code.
> >
> > I fixed the problem by enclosing the revCloseDatabase in a try/catch
> block
> > with no action for the catch but does anyone know why this might be
> > happening? Maybe Livecode automatically closes any open databases on
> exit
> > on Windows boxes but not on Macs?
> >
> > Pete
> > lcSQL Software <http://www.lcsql.com>
> > _______________________________________________
> > use-livecode mailing list
> > use-livecode at lists.runrev.com
> > Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> > http://lists.runrev.com/mailman/listinfo/use-livecode
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
>
More information about the use-livecode
mailing list