[Newbies] How can I execute a script on carriage return?

K. K. Subramaniam kksubbu.ml at gmail.com
Mon Feb 28 02:11:16 UTC 2011

On Friday 25 Feb 2011 12:07:42 pm Steve Thomas wrote:
> How do I print integers or specify that I only want 2 digits to the right
> of the decimal point? (Below is my script).
> script1
> | tmpStr |
> tmpStr := 'Im a Bot.\My position is: ' withCRs , self getLocation
> printString , '\and my direction is:' withCRs , self getHeading
> printString. self sayText: tmpStr

see printShowingDecimalPlaces: in Integer>>printing category. Also search for 
'places' in message window for other options.

HTH .. Subbu

More information about the Beginners mailing list