Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Anchor for two editboxes
Message
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows Server 2012
Network:
Windows 2008 Server
Database:
MS SQL Server
Application:
Web
Miscellaneous
Thread ID:
01616840
Message ID:
01616874
Views:
31
>>First, thank you.
>
>No problemo
>
>
>>
>>Here is what I do in my INIT method of the form.
>>
>>1. Dynamically add container to the form (where the edit boxes reside). The snippet of the code is as follows:
>>
>>	thisform.pageframe1.page1.AddObject( "fields_container", "fields_container" )
>>
>>2. Dynamically add a container (not related to the edit boxes) on the top of the form and adjust the height of the form and .top value of all controls.
>>3. Set the anchor value of the edit boxes according to your suggestions.
>>
>>I probably need to set the anchor values before step 2 (before adding another container and re-sizing the form).
>
>I guess fields_container has a default anchor value, then in step #2 when you resize the form you are resizing the container and the proper anchor value of the edit boxes are not yet set, my first try would be to swap steps 2 and 3

I commented the step 2 completely. So now it is Step 1 and then Step 2. Now the formatting of the form is completely messed up. I will try something different.

One more thing I need to mention. In the step 3 (now step 2) I set the Anchor of pageframe and the container before setting anchor of the edit box. As follows:
thisform.pageframe1.Anchor = 5
thisform.pageframe1.page1.fields_container.Anchor = 5
thisform.pageframe1.page1.fields_container.EditBox1.Anchor = 75
thisform.pageframe1.page1.fields_container.EditBox2.Anchor = 30
If you see anything that may need to be changed, please let me know.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Reply
Map
View

Click here to load this message in the networking platform