The first replies you have are excellent technical ways to enforce a destruct order. They will work fine for you. You may want to use OO principles to get a more direct and self-contained solution.
Since the "Thanks, stop now" command is for the serial port connection, you can make it part of that object's destructor by including it in a sub DESTROY for the COM port object.
After Compline,
Zaxo
In reply to Re: Destructor Order
by Zaxo
in thread Destructor Order
by sgifford
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |