Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 [Tutorial] How to make your turing programs use the printer.
Index -> Programming, Turing -> Turing Tutorials
Goto page Previous  1, 2
View previous topic Printable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Dan




PostPosted: Tue Feb 21, 2006 2:29 pm   Post subject: (No subject)

jamonathin wrote:
I know you cannot print images in turing without using the print button located at the top of the page. But if you compile your program into .exe format, the print button doesn't work. I'm guessing Turing doesn't throw that info in when compliling. Anyone know a way around this?


The 1st thing that comes to mind whould be calling a progame not made in turing threw turing to do the job. Tho when turing gets complied odd things start happening and even that may not work.

Another idea whould be to use turings ablity to save images from it's drawing screen. You could save the screen to a bmp file and then maybe there is a way to call paint where it will print the file. Tho this whould be largery dependtent on ms paint and that is never good.

My recomendation whould be to just save the screen using turings pics comands and tell the user where it is or let them pic where to put it.
Computer Science Canada Help with programming in C, C++, Java, PHP, Ruby, Turing, VB and more!
Sponsor
Sponsor
Sponsor
sponsor
jamonathin




PostPosted: Thu Feb 23, 2006 4:06 pm   Post subject: (No subject)

Ok Dan, sounds good. Thanks Smile
efan41




PostPosted: Tue Dec 08, 2009 2:37 pm   Post subject: Re: [Tutorial] How to make your turing programs use the printer.

is it possible to use a flexible array : string instead of actual text to send to printer, because I'm trying and it's giving me the header but not the text it's supposed to be printed.

code:
[syntax="Turing"]
open : dataout, "printer", put
    for c : 1 .. t - 1
        put : dataout, character (t)
    end for
    close : dataout
[/syntax]


Please help ASAP it's part of a project due next friday
mirhagk




PostPosted: Tue Dec 08, 2009 2:48 pm   Post subject: RE:[Tutorial] How to make your turing programs use the printer.

the problem does not lie in the printing code, but is there anything in character?? please post more code so I can see the problem.
Superskull85




PostPosted: Tue Dec 08, 2009 3:04 pm   Post subject: Re: [Tutorial] How to make your turing programs use the printer.

efan41 @ Tue Dec 08, 2009 2:37 pm wrote:
is it possible to use a flexible array : string instead of actual text to send to printer, because I'm trying and it's giving me the header but not the text it's supposed to be printed.

code:
[syntax="Turing"]
open : dataout, "printer", put
    for c : 1 .. t - 1
        put : dataout, character (t)
    end for
    close : dataout
[/syntax]


Please help ASAP it's part of a project due next friday

In your code t is the upper index of your array, and c is the incremental value. Just swap those two and you should be fine.
mirhagk




PostPosted: Tue Dec 08, 2009 3:07 pm   Post subject: RE:[Tutorial] How to make your turing programs use the printer.

oh yeah sorry I didn't even catch that, lol sorry long night yeah right now all your code does is print the last variable over and over
Display posts from previous:   
   Index -> Programming, Turing -> Turing Tutorials
View previous topic Tell A FriendPrintable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 2 of 2  [ 21 Posts ]
Goto page Previous  1, 2
Jump to:   


Style:  
Search: