Switch from GRAPHICS to Text Output

Matteo
Posts: 16
Joined: Thu Jan 19, 2017 1:14 pm
My devices: iPhone 5S
Flag: Italy

Re: Switch from GRAPHICS to Text Output

Post by Matteo »

Thanks to you all! Thanks George for your code, now I try to do some experiments writing some examples of calculations and switching from text and graph screen, for now I don't need interactive prompts during executions, only switching between screens without altering the execution of the entire code.
Again thanks for your time!
Matteo

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: Switch from GRAPHICS to Text Output

Post by rbytes »

I got a private message that this report is closed. What does that mean exactly?
The only thing that gets me down is gravity...

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

Re: Switch from GRAPHICS to Text Output

Post by Mr. Kibernetik »

rbytes wrote:
Sun Jan 29, 2017 3:19 pm
I got a private message that this report is closed. What does that mean exactly?
This means that the report you added to this topic is closed.

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: Switch from GRAPHICS to Text Output

Post by rbytes »

What was the result of the report?
The only thing that gets me down is gravity...

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

Re: Switch from GRAPHICS to Text Output

Post by Mr. Kibernetik »

rbytes wrote:
Sun Jan 29, 2017 3:31 pm
What was the result of the report?
And what result do you expect?
This was something off-topic, not about "Switch from GRAPHICS to Text Output".

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: Switch from GRAPHICS to Text Output

Post by rbytes »

I expected that off-topic comments would be corrected or deleted.
The only thing that gets me down is gravity...

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

Re: Switch from GRAPHICS to Text Output

Post by Mr. Kibernetik »

rbytes wrote:
Sun Jan 29, 2017 3:35 pm
I expected that off-topic comments would be corrected or deleted.
Just don't create new off-topic comments, and everything will be fine.

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: Switch from GRAPHICS to Text Output

Post by rbytes »

Please then apply that rule to all members, and i agree that everything will be fine.
The only thing that gets me down is gravity...

Matteo
Posts: 16
Joined: Thu Jan 19, 2017 1:14 pm
My devices: iPhone 5S
Flag: Italy

Re: Switch from GRAPHICS to Text Output

Post by Matteo »

Hi! this is my first attempt to do what I was asking about switching between graph and txt output during any SmartBasic calculation:

Code: Select all

REM --- We start in the graph page:
GRAPHICS
button_text$ = "TXT"
BUTTON "a" TEXT button_text$ AT 250,10

i=0
LOOP:
IF i<50 THEN
i=i+1
x=i
y=2*x+4
REM --- What I want to see in the text page:
PRINT x, y
REM --- and what I want to see in the graph page:
DRAW PIXEL x,y COLOR 1,0,0
DRAW CIRCLE x,y SIZE 2
PAUSE 0.05
ELSE
SLOWDOWN
GOTO switch_page
ENDIF

switch_page:
IF button_text$ = "TXT" AND BUTTON_PRESSED("a") THEN
 button_text$ = "RGB"
 BUTTON "a" TEXT button_text$
 TEXT
 GOTO LOOP
ENDIF
IF button_text$ = "RGB" AND BUTTON_PRESSED("a") THEN
 button_text$ = "TXT"
 BUTTON "a" TEXT button_text$
 GRAPHICS
 GOTO LOOP
ENDIF
GOTO LOOP
I ask if user can scroll up and down the txt output after the STOP of the program, in this case I cant see the very first values in the txt output.Can you help me?
Other question: does a command exist to return automatically in the source code editor after the STOP of the program, avoiding to remain in the output screen until user touches the 'Return' key in the upper toolbar?
Thanks very much!
Matteo

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

Re: Switch from GRAPHICS to Text Output

Post by Mr. Kibernetik »

Matteo wrote:
Fri Feb 03, 2017 9:35 pm
I ask if user can scroll up and down the txt output after the STOP of the program, in this case I cant see the very first values in the txt output.Can you help me?
Other question: does a command exist to return automatically in the source code editor after the STOP of the program, avoiding to remain in the output screen until user touches the 'Return' key in the upper toolbar?
Number of lines which text output can keep is not unlimited.

No. When program stops it never immediately switches to code editor. You always have a choice to go to code editor or to file manager.

Post Reply