Thank you for the code.
I subsituted the program name to claimpack , the macro works fine its just it will not count and the reason I found out today is that Claimpack acually acts like it's closing the program and restarting but it's not. I noticed that the Window's name is acuallty ClaimPack and then the image name or the folder where the image is from so it's like "Formwave completion {XXXXXXXXX}" X as numbers and letters so ClaimPack is acually just loading another image and not closing the acual program but it's acting like the acual image is whole another program cuz I tested it in "Activate Window" in marcos, you can select the program you are running and i set the counters so it will keep on activiating it all the time no metter what, after i get done with image it would say "FWBW.EXE XXXXXXX not found macro aborting".
Maybe it can be done make count but it would be much much more complex tasj from what i'm thinking but thank you so much for you help i really appriciate it.