0

I am writing a small project in c# to add thumbnail icons to a bunch of game folders on my PC. Is it possible to get the title of a window without running the program creating that window?

EG: Let's say I have a game executable installed to "C:/games/ExampleGame/bin/game.exe", When launched it creates a window called "VG 1"

I need to retrieve the "VG 1" string without actually running game.exe.

The purpose behind needing the Window title is so that I can scrape some data using the game's actual name. In a situation where the folder containing the game is assumed to be incorrect or inaccurate, and the executable is assumed to be named something generic.

Jason Brown
  • 127
  • 2
  • 13
  • 5
    No, it is not possible – Sir Rufo Jun 09 '19 at 08:08
  • `if (Random.Next(2) == 0) { new Form1().Show(); } else { new Form2().Show(); }`. – GSerg Jun 09 '19 at 08:17
  • You [probably](https://meta.stackexchange.com/q/66377/147640) want https://stackoverflow.com/q/12347215/11683. – GSerg Jun 09 '19 at 08:20
  • The executable can pass any hardcoded string for lpWindowName parameter of CreateWindow API => so it is not possible. You can just grab the resources of the .exe – Castorix Jun 09 '19 at 09:10

0 Answers0