Manual update of a clickonce deployment


Author
Message
Bill Cunnien
Bill Cunnien
StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)
Group: Forum Members
Posts: 785, Visits: 3.6K
After my application is running, I have a timer that periodically checks for new updates.  When it finds that there are updates available, the application updates the status bar alerting the user to the new update.  The user can choose to update the application by simply clicking the menu item, "Help" - "Get Updates."  When they click that menu item, I throw up a WaitWindow (love these little guys) letting the user know that an update is in progress.  After the update is complete, I am hiding that WaitWindow, then I send the command to the application to restart.  Everything seems to be ok, except I get a small, standard Windows message box that is titled "MicroFour StrataFrame Base" and a message that says "Disposed..."  The application restarts just fine, but this message box hangs around until I click the OK button.  Looks like there is no other damage anywhere.  Why is this message box popping up?  Can I do anything about this?  Is it related to the WaitWindow somehow?

Thanks!
Bill

Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
Well, something is being referenced that is already disposed.  I would need more details before I could give you any type of direction, stack-trace, etc.
Bill Cunnien
Bill Cunnien
StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)
Group: Forum Members
Posts: 785, Visits: 3.6K
Here is the code snippet:

waitWindow1.ShowWaitWindow();
ApplicationDeployment ad = ApplicationDeployment.CurrentDeployment;
ad.Update();
waitWindow1.HideWaitWindow();
Application.Restart();

The anomaly only appeared after I decided to throw in a WaitWindow for aesthetic purposes.  I removed the wait window and it works fine...no message box.  Like this:

ApplicationDeployment ad = ApplicationDeployment.CurrentDeployment;
ad.Update();
Application.Restart();

I'll see if I can work up a stack trace for you.

Thanks,
Bill


Bill Cunnien
Bill Cunnien
StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)StrataFrame VIP (1.1K reputation)
Group: Forum Members
Posts: 785, Visits: 3.6K
This works:

waitWindow1.ShowWaitWindow();
ApplicationDeployment ad = ApplicationDeployment.CurrentDeployment;
ad.Update();
Application.Restart();

For some reason, calling HideWaitWindow() bothers the application restart sequence.

Cool
Bill


Trent Taylor
Trent Taylor
StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)StrataFrame Developer (10K reputation)
Group: StrataFrame Developers
Posts: 6.6K, Visits: 6.9K
Glad you got it going.
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search