Nick, sorry for the delay in getting back.
If your task returns Cancel as a result, then the state is *not* stored in the EG project. You might have realized that by now.
So, then you are on your own for serializing the state elsewhere, if the state is not project specific. You can use .NET methods to read/write a file of your own design into a safe location, such as somewhere in %appdata% where the user is sure to have write access.
Chris