Sign in to follow this  
Followers 0
oller

WinSetState($handle, "", @SW_MAXIMIZE) Problem

7 posts in this topic

Hi there, sorry for bugging you with my lack of knowledge.

I try to maximize a programm (Rhapsody)

I did not get farter than this:

$status = WinGetState("Rhapsody")

WinSetState($handle, "", @SW_MAXIMIZE)

What happens when I run the script is:

- Rhapsody "hangs" does not longer respond to input

- Task Manager shows two instances of Rhapsody.exe. I don't understand why.

I tried to figure out what is going on using this script:

$status = WinGetState("Rhapsody")

MsgBox ( 4096, "title", $status )

That returns:

39 for maximized

7 for what you call it (between maximized and minimized)

5 for minimized

Those codes are not in the manual. What do they mean?

Where is my mistake?

Regards Oller

Share this post


Link to post
Share on other sites



That returns:

39 for maximized

7 for what you call it (between maximized and minimized)

5 for minimized

Those codes are not in the manual. What do they mean?

39 = 32 + 4 + 2 + 1 see helpfile for what they mean....


Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

#3 ·  Posted (edited)

39 = 32 + 4 + 2 + 1 see helpfile for what they mean....

Thanks. So this is like it should be.

But why is Rhapsody behaving so funny? The same script on other windows works fine.

Edited by oller

Share this post


Link to post
Share on other sites

Thanks. So this is like it should be.

But why is Rhapsody behaving so funny? The same script on other windows works fine.

Dunno... don't have Rhapsody ... What is the value of $Handle ?


Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

Dunno... don't have Rhapsody ... What is the value of $Handle ?

$handle = WinGetHandle("Rhapsody", "")

MsgBox ( 4096, "title", $handle )

00240236 (maximized and normal)

00160252 (minimized)

Is that normal to get differnt handles?

-Oller

Share this post


Link to post
Share on other sites

#6 ·  Posted (edited)

$handle = WinGetHandle("Rhapsody", "")

MsgBox ( 4096, "title", $handle )

00240236 (maximized and normal)

00160252 (minimized)

Is that normal to get differnt handles?

-Oller

Maybe it has second hidden window....

You also said that the WinGetState() returns a 5 for Minimized which means 4+1 and the 2="Window Is visible" is missing. This would indicate a hidden window.

Edited by JdeB

Visit the SciTE4AutoIt3 Download page for the latest versions        Beta files                                                          Forum Rules
 
Live for the present,
Dream of the future,
Learn from the past.
  :)

Share this post


Link to post
Share on other sites

Maybe it has second hidden window....

You also said that the WinGetState() returns a 5 for Minimized which means 4+1 and the 2="Window Is visible" is missing. This would indicate a hidden window.

Right!

and after:

WinSetState($handle, "", @SW_MAXIMIZE)

there are two rhapsody.exe in the taskmanager!. I think the second one becomes visible with WinSetState. Well thanks. I keep trying.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0