N
Nick
Hi there,
I know this question has been asked many a time before, and I have
actually read 90% of the replies regarding it, unfortunately no solution is
working for me at the moment.
I create the button on startup and keep a reference to the
CommandBarControlPtr object. On shutdown, rather than attempting to find
the button again, I use that reference, which still has exactly the same
address as it did when it was functioning, but for some reason or another
the object is invalid.
I therefore cannot remove the button from the toolbar. I've tried in
onBeginShutdown and onDisconnection, but it's not working anywhere, the
second I touch the Delete method it freaks out. I'm sure there must be some
logical reasoning behind this, but everything I have tried upto this point
has failed to help, the object seemingly falls out of scope.
Any ideas on how I can resolve this?
Nick.
I know this question has been asked many a time before, and I have
actually read 90% of the replies regarding it, unfortunately no solution is
working for me at the moment.
I create the button on startup and keep a reference to the
CommandBarControlPtr object. On shutdown, rather than attempting to find
the button again, I use that reference, which still has exactly the same
address as it did when it was functioning, but for some reason or another
the object is invalid.
I therefore cannot remove the button from the toolbar. I've tried in
onBeginShutdown and onDisconnection, but it's not working anywhere, the
second I touch the Delete method it freaks out. I'm sure there must be some
logical reasoning behind this, but everything I have tried upto this point
has failed to help, the object seemingly falls out of scope.
Any ideas on how I can resolve this?
Nick.