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

Username:   Password: 
 RegisterRegister   
 How do i use Font.Draw on a changing var?
Index -> General Discussion
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
TechLacky




PostPosted: Sat Jan 14, 2012 10:21 pm   Post subject: How do i use Font.Draw on a changing var?

Oi, can enyone help me with turing?

I want to know how to use Font.Draw on a chaning var:
-------------------------------------------------------------------------------------
var a : int
var font : int
a := 0
font := Font.New ("Arial:20")

loop
a := a +1
%Tried putting "Font.Draw (" "+a+" ", 1, 1, font, black)" but doesnt work... Confused %
end loop
----------------------------------------------------------------------------------
help would be greatly appreciated, Thanks Surprised
Sponsor
Sponsor
Sponsor
sponsor
RandomLetters




PostPosted: Sat Jan 14, 2012 10:39 pm   Post subject: RE:How do i use Font.Draw on a changing var?

Aside from the infinite loop and not clearing the screen, you can convert integers to strings using

intstr(a)

Turing:


var a : int
var font : int
a := 0
font := Font.New ("Arial:10")

loop
   cls
   a := a +1
   Font.Draw (intstr(a), 1, 1, font, black)
   exit when a = 1000
   delay(10)
end loop
Display posts from previous:   
   Index -> General Discussion
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 2 Posts ]
Jump to:   


Style:  
Search: