I have a c# program that watches another application(process) and needs to act when a Dialog is closed.
My program :
- calls a save dialog in another app
- a dialog window opens saying info is being saved
- I am looping and need to know when this dialog closes (ie save is complete)
Currently I use the following but it does not work as the name varies.
fileDialog = FindWindow("#32770", "Download complete");
The dialog has variable names so what I think I need to do is to
- Call a method to Find All Dialog Windows #32770
- I can then either count them and when count decreases by one I can assume completion OR I can check the names and look for a subset of text.
I am new to WinAPI so if anyone can give me a decent code snippet then that would be great.
I have read many web pages but have not really understood the solutions.
Thanks in advance and have a great weekend.