Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Resize method causes the error
Message
From
10/01/2023 11:54:53
 
General information
Forum:
Visual FoxPro
Category:
Contracts, agreements and general business
Miscellaneous
Thread ID:
01685755
Message ID:
01685767
Views:
29
>>>Hi,
>>>
>>>I have a form with a grid in the left side of the form. The grid is data driven (that is created when the form is instantiated).
>>>What happens is when a user resized the form to such small size that the left-side grid is just a line (or maybe two vertical lines), the run-time error occurs:
>>>
>>>Error with left_pane_grid - width : Expression evaluates to an illegal value
>>>
>>>
>>>How do you suggest to prevent this problem?
>>>
>>>UPDATE. There is a custom (my) code in the method RESIZE. The code in this methods set the .Width of the grid.
>>>I need to "catch" it before it gets too small.
>>
>>Check MinWidth in Help...!
>
>It looks like this property (in Help) is only applied to form or _screen. When I view all the properties of the grid, I don't see this property.

That's correct, it applies to the form. Seems like exactly what you are looking for? Just set it to a value that's big enough to avoid the error.

Having said that, have you considered using anchors for all the objects? That's the modern way to do it.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform