Using AnimateWindow and set the transparency for a form with no titlebar
Hello, I am sort of new to Visual Basic, but i am currently practicing VB by writing a cd player. I recently discovered how to use the AnimateWindow and how to set transparency for a form. I want to get into subclassing, because it would make my programming more powerful, and because I currently have a problem.
I have tried to use the AnimateWindow function on a titlebar-less form(with a custom shape) but nothing will execute. Meaning that if I want to make a fade in effect it wont unless i have a titlebar. I supose i would have to do some subclassing, but i really need explanations on concepts and techniques. Thanx a lot for answering. Amon Ra(Alexis)
PS : I am on Windows 2000
Last edited by Amon Ra; Feb 23rd, 2001 at 09:31 PM.
I don't think that you can use animatewindow on a window without a titlebar. The purpose of the function is to flash the title bar of a window. It might still work if your window is minimized to the task bar however.
Actually AnimateWindow is used to make transition effects with constants such as AW_BLEND, AW_HIDE, AW_ACTIVATE,AW_VER_POSITIVE,AW_VER_NEGATIVE,AW_HOR_POSITIVE,AW_HOR_NEGATIVE,AW_CENTER..
Hmm. The flashing form title bar is the only place i have ever seen it used. It is not in either my Microsoft Win-32 Programmer's Reference Or my Visual Basic Programmer's Guide to teh Win32 API. Where did you get your info?
I was wondering how MS made their menus fade in and fade out. I looked on the web and i found the function. i wrote a class with many possible combinations with flages, but it works only on a window that has a titlebar.So i was thinking i had to do some subclassing.
have a look at the class(tell me if thereis a bug)
By the way, it runs only on Win2k, so that is why u might not have seen it.