Copy/Paste printed output

Post Reply
davey110
Posts: 82
Joined: Mon Dec 26, 2016 11:01 pm
My devices: iPod touch 6
iPad mini 2
Flag: Canada

Copy/Paste printed output

Post by davey110 »

When I run a program that prints text output, I can normally Copy/Paste this output to another program or app after the program ends.
I have written a program that is mostly GRAPHICS mode, but also prints some text on the TEXT screen. But this text will not Copy/Paste. "Select" text does not even show up. I have ensured that the program is in TEXT mode while the text is being output, as well as just before it ends. Is there something in Graphics mode that blocks the Copy/Paste function? Is there a way around it? I have tried running other text only programs in Graphics mode and switching back to Text, then Copy/Paste works fine. I have SB v6.9 on an iPad Mini.

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: Copy/Paste printed output

Post by Mr. Kibernetik »

I do not understand the problem.
The text printed by PRINT is selectable for copying after TEXT mode is switched into.

davey110
Posts: 82
Joined: Mon Dec 26, 2016 11:01 pm
My devices: iPod touch 6
iPad mini 2
Flag: Canada

Re: Copy/Paste printed output

Post by davey110 »

It works fine in other programs, but for this particular program it won't work. I just wondered if sliders or buttons in Graphics mode could interfere with it somehow. I don't understand it either.
Thank you.

davey110
Posts: 82
Joined: Mon Dec 26, 2016 11:01 pm
My devices: iPod touch 6
iPad mini 2
Flag: Canada

Re: Copy/Paste printed output

Post by davey110 »

I REMed out the buttons and sliders, and the Copy/Paste works OK. By REMing out various parts of the program, I narrowed it down to Sliders or Buttons. Creating either Sliders or Buttons disables the Copy/Paste ability, even it if it was not in GRAPHICS mode. Without either, it works fine.

davey110
Posts: 82
Joined: Mon Dec 26, 2016 11:01 pm
My devices: iPod touch 6
iPad mini 2
Flag: Canada

Re: Copy/Paste printed output

Post by davey110 »

I have solved the problem by writing a small program to Read the Clipboard and Print the results from the main program.
The main program WRITEs the values to the Clipboard, and then RUNs the second program, which READs the values from the Clipboard and Prints them to the screen. The values on the screen will now Copy/Paste normally.

The paragraph in the Help file, (Input & Output section) clued me in to this solution. It's not too clumsy, since the 2nd program is run by the main one. If there is a more direct solution, I would appreciate hearing about it.

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: Copy/Paste printed output

Post by Mr. Kibernetik »

You can print values to file if you need a text copy of results.

davey110
Posts: 82
Joined: Mon Dec 26, 2016 11:01 pm
My devices: iPod touch 6
iPad mini 2
Flag: Canada

Re: Copy/Paste printed output

Post by davey110 »

Thank you. That would also solve the problem.

Post Reply