<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 12pt;
font-family:Calibri
}
--></style></head>
<body class='hmmessage'><div dir='ltr'>Hi,<br>Yes. all of those will work to convert float to string for output to file. There is probably a better way of writing CM pattern float output to a file as strings than my example, but at least this gets me going again. <br><br>Regards,<br>Jim<br><br><br>(number->string 123)
<br>(object->string 123.45)
<br>(format #f "~G" 123)
<br>(format #f "~f" 123.456)<br><br><div><br>> (define ouf1 (open-output-file "myfloats.txt"))<br>> (define outstring "init")<br>> <br>> (define (myfloats total)<br>> (let ((test 0))<br>> (process with mytable = (make-heap '(.5 1 2.5 3))<br>> until (= test total)<br>> do<br>> (set! outstring (next mytable)) ;***stuck here with format conversion ***<br>> (set! outstring (string-append outstring (string #\newline)))<br>> (display outstring ouf1)<br>> (print (next mytable))<br>> (set! test (+ test 1)) <br>> )))<br>> <br>> (sprout (myfloats 10) )<br>> <br>> (close-output-port ouf1)<br><br></div>                                            </div></body>
</html>