Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
333 views
in Technique[技术] by (71.8m points)

c# - How to find out if an MSI I just installed requested a Windows reboot?

I've built a setup.exe in C# that runs several chained MSI's (with the /QUIET /NORESTART). At the end I'd like to check if a reboot is needed in the machine (that is, if one of the MSI's requested a reboot).

How can I detect so?

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

The following registry location has the information:

Key HKLMSystemCurrentControlSetControlSession Manager, value PendingFileRenameOperations

Source: http://technet.microsoft.com/en-us/sysinternals/bb897556.aspx


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...