As I am no "original" C/C++ programmer, I don't know much about Windows programming.
What I did now was the following:
- Use System.Diagonstics.Process objects for all created instances:
So I can get all the handles to the Winamp instances that I use and
close them again afterwards.
- When trying to find the playlist window, that is attached to each
of the Winamps, I browse the window list using the API call
FindWindowEx (...) with certain parameters.
It took me ages and some help from a friend to make this thing work.
- Then I compare the playlist's owner with my Winamp window to find
the matching instances.
Actually it wouldn't be that difficult as I suppose to know now and you idea with using different class names sounds helpful as well, but
my code works fine now
Maybe you've got some code snippets that show, how to work with this ClassRegister (..) (??) stuff in C#. I don't have a clue yet.
As soon as I have the C# code above in a way that doesn't embarrass me to post it in the forum, you'll get notice to have a look at the source code. Maybe somebody else needs some type of library like this.