Jump to content

Recommended Posts

  • Solution
  • 8 months later...
Posted (edited)

If the program crashes for any reason, the separated empty section will remain. Then, when the program is run again, the program code will ignore the separated section and display the program bar on the remaining section. ?!!!!!

 

 

 

 

Spoiler

failed.PNG

 

Edited by Parsix
Posted

@Parsix

Try replacing the beginning of the example function with this :

Func Example()
  Local $tAppBarData = DllStructCreate($tagAPPBARDATA)
  $tAppBarData.cbSize = DllStructGetSize($tAppBarData)

  If WinExists("SHAppBarMessage") Then RunWait('TaskKill /PID ' & WinGetProcess("SHAppBarMessage") & ' /F', '', @SW_HIDE)
  Local $hGUI = GUICreate("SHAppBarMessage", 80, @DesktopHeight, 0, 0, $WS_POPUP, $WS_EX_TOOLWINDOW + $WS_EX_TOPMOST)

Works well for me...

Posted
2 hours ago, Nine said:

@Parsix

Try replacing the beginning of the example function with this :

Func Example()
  Local $tAppBarData = DllStructCreate($tagAPPBARDATA)
  $tAppBarData.cbSize = DllStructGetSize($tAppBarData)

  If WinExists("SHAppBarMessage") Then RunWait('TaskKill /PID ' & WinGetProcess("SHAppBarMessage") & ' /F', '', @SW_HIDE)
  Local $hGUI = GUICreate("SHAppBarMessage", 80, @DesktopHeight, 0, 0, $WS_POPUP, $WS_EX_TOOLWINDOW + $WS_EX_TOPMOST)

Works well for me...

not work

"SHAppBarMessage" It has been closed abruptly before and there is no window with the above name.

As shown in the image, when the program is run again, the form will appear after the cropped bar because x=0 is the previous cropped area for it.

A solution must be found to recover the partitioned area, especially when the program closes due to an unknown error without properly executing the exit commands.

 

for test :

I compiled the program and then ran it, so far everything is fine

To test the program, I ended the task from the Windows task manager, when I run the program again, the program behaves like the picture in the previous post

Posted
16 minutes ago, Parsix said:

for test :

I compiled the program and then ran it, so far everything is fine

To test the program, I ended the task from the Windows task manager, when I run the program again, the program behaves like the picture in the previous post

It seems to be a bug in Windows 10 (I was able to reproduce the issue).  In Windows 11, the bad behavior has disappeared, as it is working correctly now.  At this stage, I have no idea how to recuperate the lost region.

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
×
×
  • Create New...