Sometimes Form Modal or Non-Modal

New to Gambas? Post your questions here. No question is too silly or too simple.
User avatar
gambafeliz
Posts: 139
Joined: Friday 2nd September 2022 7:50pm
Location: I live in the same city as Picasso

Re: Sometimes Form Modal or Non-Modal

Post by gambafeliz »

At the moment the closest thing to what I'm looking for is setting Form1 utilities=True

But the problem is that it can't be resized.
For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
User avatar
thatbruce
Posts: 161
Joined: Saturday 4th September 2021 11:29pm

Re: Sometimes Form Modal or Non-Modal

Post by thatbruce »

Yes, no it cant. One of those things about utility windows is that they use the design size.
Search me?
Have you ever noticed that software is never advertised using the adjective "spreadable".
User avatar
BruceSteers
Posts: 1523
Joined: Thursday 23rd July 2020 5:20pm
Location: Isle of Wight
Contact:

Re: Sometimes Form Modal or Non-Modal

Post by BruceSteers »

gambafeliz wrote: Monday 5th December 2022 4:55pm At the moment the closest thing to what I'm looking for is setting Form1 utilities=True

But the problem is that it can't be resized.
A modal window can be expanded larger than the initial size set in the IDE but not shrunk smaller.

The answer...
Make the Form size in the IDE form designer the Minimum size required, lets say 100x100

In Form_Open() event resize it to the desired size..
Me.Resize(500, 300)

Window now opens with size 500x300 and can be resized down to 100x100
If at first you don't succeed , try doing something differently.
BruceS
User avatar
gambafeliz
Posts: 139
Joined: Friday 2nd September 2022 7:50pm
Location: I live in the same city as Picasso

Re: Sometimes Form Modal or Non-Modal

Post by gambafeliz »

Very good :)

I salute you. Thanks, I didn't know, I already thought about changing the size in Form_Open but I see that the user cannot shrink the window and that may be a problem, at whim on the part of the user.

Hey, thank you very much for your interest.

Note: I don't find any problem in my code, seriously, even if you are right.
For your misfortunes I am Spanish and I only know Spanish, please, be patient with me, Thank you. :)
Post Reply