Unable ti switch from windowed screen to fullscreen

Just starting out? Need help? Post your questions and find answers here.
Nells
New User
New User
Posts: 6
Joined: Tue Mar 02, 2004 12:43 pm

Unable ti switch from windowed screen to fullscreen

Post by Nells »

Hi !
I did this code

Code: Select all

Procedure switchScreen()
  CallDebugger
  If screen = 1
    CloseScreen()
    OpenWindow(0, 0, 0, 800, 600, #PB_Window_SystemMenu | #PB_Window_MinimizeGadget, #AppName)
    OpenWindowedScreen(WindowID(), 0, 0, 800, 600, 0, 0, 0)
    screen = 0
  Else
    CloseScreen()
    CloseWindow(0)
    If OpenScreen(#SCRWidth, #SCRHeight, #SCRDepth, #AppName)
      screen = 1
    Else
      MessageRequester(#AppName, "Impossible de passer au mode plein écran")
      OpenWindow(0, 0, 0, 800, 600, #PB_Window_SystemMenu | #PB_Window_MinimizeGadget, #AppName)
      OpenWindowedScreen(WindowID(), 0, 0, 800, 600, 0, 0, 0)
      screen = 0
    EndIf
  EndIf
EndProcedure
Yes, I'm french ^^

So, I got the message "Impossible de passer au mode plein écran" when I switched from fullscreen ^^

and full to windowed doesn't work neither

Could someone explain why it's impossible to switch, or maybe there's an error in the code?
Nells
New User
New User
Posts: 6
Joined: Tue Mar 02, 2004 12:43 pm

Post by Nells »

Nobody can help me? :cry:

Well, it's not that important, but can be useful ;)
Shopro
Enthusiast
Enthusiast
Posts: 148
Joined: Tue May 13, 2003 8:05 am

Post by Shopro »

hi,

you can find an example in the code archives. It contributed by myself :)

-Shopro
Kale
PureBasic Expert
PureBasic Expert
Posts: 3000
Joined: Fri Apr 25, 2003 6:03 pm
Location: Lincoln, UK
Contact:

Post by Kale »

Maybe this will help:
viewtopic.php?t=7772
:)
--Kale

Image
Shopro
Enthusiast
Enthusiast
Posts: 148
Joined: Tue May 13, 2003 8:05 am

Post by Shopro »

ah, yes, that's the one :)

-Shopro
Post Reply