Xojo Developer Conference
25/27th April 2018 in Denver.
MBS Xojo Conference
6/7th September 2018 in Munich, Germany.

[MBS] Resolution class not working under win 32 (MBS Xojo Plugin Mailinglist archive)

Back to the thread list
Previous thread: [MBS] HTML encoding example
Next thread: [MBS] 3.1pr7


Re: [MBS] MIDI Destinations and External Devices   -   Ron Benditt
  [MBS] Resolution class not working under win 32   -   Marc Klureza
   Re: [MBS] Resolution class not working under win 32   -   Christian Schmitz

[MBS] Resolution class not working under win 32
Date: 25.01.03 21:23 (Sat, 25 Jan 2003 15:23:57 -0500)
From: Marc Klureza
Hi all,
I have this code on a push button:

dim MyDisplay as displayMBS
dim MyRes as ResolutionMBS
MyDisplay = getDisplay(0)
MyRes = MyDisplay.GetCurrentResolution()
MsgBox "ResolutionMBS resolution is " +str(MyRes.width) +" x "
+str(MyRes.height) + ". With a depth of " +str(MyRes.Depth)
MsgBox "displayMBS resolution is " +str(MyDisplay.width) +" x "
+str(MyDisplay.height) + ". With a depth of " +str(MyDisplay.Depth)


On my Mac, if my monitor is set to 1024x768, I get a message box that
says "ResolutionMBS resolution is 1024 x 768 With a depth of 32" and
then "displayMBS resolution is 1024 x 768 With a depth of 32" This is
as expected.

On virtual PC (win 98 OS) I get ResolutionMBS resolution is 7599304e +
06 x 3256 With a depth of 7.740600e+06" and then "displayMBS resolution
is 0 x 0 With a depth of 0" Hmmmmmm....

If I change the resolution using the SwitchTo command from within the
program, the displayMBS info will match the switch even if I change the
resolution outside of the program. The ResolutionMBS numbers don't
change.

Any ideas on how to get the correct resolution info inside of Windows?

TIA

--Marc Klureza
Systems Administrator
Museum of Science
Boston, MA

Re: [MBS] Resolution class not working under win 32
Date: 27.01.03 01:14 (Mon, 27 Jan 2003 01:14:44 +0100)
From: Christian Schmitz
> Hi all,
> On virtual PC (win 98 OS) I get ResolutionMBS resolution is 7599304e +
> 06 x 3256 With a depth of 7.740600e+06" and then "displayMBS resolution
> is 0 x 0 With a depth of 0" Hmmmmmm....

I think I got it fixed for the next prerelease.

> If I change the resolution using the SwitchTo command from within the
> program, the displayMBS info will match the switch even if I change the
> resolution outside of the program. The ResolutionMBS numbers don't
> change.

Don't we have an update call?

*later*

Ok. None found. I add one and a new example called "Current Mode" for
the next prerelease.

Mfg
Christian