[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Axiom-developer] RE: capturing output strings
From: |
Bill Page |
Subject: |
[Axiom-developer] RE: capturing output strings |
Date: |
Sun, 22 May 2005 00:44:28 -0400 |
On May 22, 2005 12:35 AM Tim Daly wrote:
> ok, so who needs to pack? :-)
Ah, I thought so! :)
> Axiom's algebra gets output to a stream called
> |$algebraOutputStream| Thus you can get the output
> you want by:
>
> )set message autoload off
> )lisp (progn
> (setq tmpout (make-string-output-stream))
> (setq save |$algebraOutputStream|)
> (setq |$algebraOutputStream| tmpout)
> (|parseAndInterpret| "(x+1)^9")
> (setq result (get-output-stream-string |$algebraOutputStream|))
> (setq |$algebraOutputStream| save)
> result)
>
>)lisp result
>
>result contains the output from axiom that you want.
Yes, excellent! It works also on Windows. That's exactly what
I wanted.
Now, I can sleep and you can pack... :)
Cheers,
Bill Page.