Confusion over when to use PAGE commands

Post Reply
User avatar
rbytes
Posts: 1338
Joined: Sun May 31, 2015 12:11 am
My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet
Location: Calgary, Canada
Flag: Canada
Contact:

Confusion over when to use PAGE commands

Post by rbytes »

TBA
Last edited by rbytes on Mon Feb 06, 2017 1:00 am, edited 1 time in total.
The only thing that gets me down is gravity...

User avatar
Mr. Kibernetik
Site Admin
Posts: 4787
Joined: Mon Nov 19, 2012 10:16 pm
My devices: iPhone, iPad, MacBook
Location: Russia
Flag: Russia

Re: Confusion over when to use PAGE commands

Post by Mr. Kibernetik »

There is an example in Interactive interface section, called "pages.txt". It shows animated overlapping pages. You can experiment with it.

In general, pages are like sheets of paper on the table. PAGE SET command makes the page on the top of other pages and "active". Active means that since that moment all newly created interface objects become children of that page.

User avatar
GeorgeMcGinn
Posts: 435
Joined: Sat Sep 10, 2016 6:37 am
My devices: IPad Pro 10.5in
IMac
Linux i386
Windows 7 & 10
Location: Venice, FL
Flag: United States of America
Contact:

Re: Confusion over when to use PAGE commands

Post by GeorgeMcGinn »

In my testing for the programmer's guide I took the approach that pages are really like FORMS and POP-UP boxes in Visual Basic.

I wrote an application for an agency that took people's information, and some questions were YES/NO, and if they answered "YES" most of the time the person needed to get more information.

For example, have you lived at your current address for less than 5 years. If they said "YES" then the person, in this case a mortgage broker, needed to have another FORM appear where all the addresses up to the last 5 or 10 years, depending on the lender, wanted. But when he/she was done entering all those other addresses, the FORM when it closed had to go back to the original FORM without losing their place, and even marking that part of the application completed.

You could have 3 or even 5 Forms open depending on the questions and answers.

So far my testing with pages performs the functions of forms like in VB, and more.

I have more testing to do for the programmer's guide, but part of this guide is to program smart, and using pages over hiding a bunch of FIELD/TEXT/BUTTONS makes coding and understanding what the program is doing much easier. Here you just have to either SHOW or HIDE a page. All the objects are affected by that one statement. Show a page and all its TEXT, FIELDS, BUTTONS become available.

As I said I have just started to test and code in pages for the guide, so if I got something wrong or missed something very important, please, don't be shy. This guide is to give not only a more detailed description on the statements, but how they are best used when writing programs.

George.
George McGinn
Computer Scientist/Cosmologist/Writer/Photographer
Member: IEEE, IEEE Computer Society
IEEE Sensors Council & IoT Technical Community
American Association for the Advancement of Science (AAAS)

User avatar
Dutchman
Posts: 860
Joined: Mon May 06, 2013 9:21 am
My devices: iMac, iPad Air, iPhone
Location: Netherlands
Flag: Netherlands

Re: Confusion over when to use PAGE commands

Post by Dutchman »

In order to get some experience in the usage of pages, I have made a demo program:
viewtopic.php?p=4457#p4457
Last edited by Dutchman on Fri Jan 20, 2023 12:13 pm, edited 1 time in total.

Henko
Posts: 822
Joined: Tue Apr 09, 2013 12:23 pm
My devices: iPhone,iPad
Windows
Location: Groningen, Netherlands
Flag: Netherlands

Re: Confusion over when to use PAGE commands

Post by Henko »

I use the page command as a window mechanism for no other reason than that the old background under a window is automatically restored when the window is closed. A second advantage is the local coordinate system of pages.

User avatar
rbytes
Posts: 1338
Joined: Sun May 31, 2015 12:11 am
My devices: iPhone 11 Pro Max
iPad Pro 11
MacBook
Dell Inspiron laptop
CHUWI Plus 10 convertible Windows/Android tablet
Location: Calgary, Canada
Flag: Canada
Contact:

Re: Confusion over when to use PAGE commands

Post by rbytes »

Thanks to all for your suggestions. I had already tried the examples mentioned, but had not been able to discern the underlying principle behind the use of the PAGE N$ SET command. Your response made it clear, Mr. K.
In general, pages are like sheets of paper on the table. PAGE SET command makes the page on the top of other pages and "active". Active means that since that moment all newly created interface objects become children of that page.
That was the "aha" moment I needed. I hope that this information will be added to the manual.
The only thing that gets me down is gravity...

User avatar
GeorgeMcGinn
Posts: 435
Joined: Sat Sep 10, 2016 6:37 am
My devices: IPad Pro 10.5in
IMac
Linux i386
Windows 7 & 10
Location: Venice, FL
Flag: United States of America
Contact:

Re: Confusion over when to use PAGE commands

Post by GeorgeMcGinn »

That aha moment – became mine in my question to you about my rectangular message box did not work and you said because I could not do that on top of an active object (the was a PM on the project you're helping on?).

Had I made them pages instead, all i need to do was move my message to the MessageBox page and just set it on.

I may take a look into that as it may save me on lines of code. I still think most of what I wrote as far as fields and draw statements still work, I just do it like you did in RadioStar. Set pages and just set them on and off as required.

My aha moment (but I may have written to many lines of code to change it now :cry:

George.

rbytes wrote:
Sun Jan 22, 2017 3:27 pm
Thanks to all for your suggestions. I had already tried the examples mentioned, but had not been able to discern the underlying principle behind the use of the PAGE N$ SET command. Your response made it clear, Mr. K.
In general, pages are like sheets of paper on the table. PAGE SET command makes the page on the top of other pages and "active". Active means that since that moment all newly created interface objects become children of that page.
That was the "aha" moment I needed. I hope that this information will be added to the manual.
George McGinn
Computer Scientist/Cosmologist/Writer/Photographer
Member: IEEE, IEEE Computer Society
IEEE Sensors Council & IoT Technical Community
American Association for the Advancement of Science (AAAS)

Post Reply