[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ns] writing from C++ to a file opened from OTcl
I suppose you could use the command function to do this, something like
Tcl_GetChannel, ex :
214 if (strcmp(argv[1], "file") == 0) {
215
216
217
218 int mode;
219 file_ = Tcl_GetChannel(tcl.interp(),
220 (char *)argv[2], &mode);
then all you need to do is sprintf to file_ in your C++ code, or use TclWrite.
>Date: Fri, 27 Oct 2000 12:55:05 +0200
>From: "Niko A. Fikouras" <[email protected]>
>X-Accept-Language: en, el
>MIME-Version: 1.0
>To: [email protected]
>Subject: [ns] writing from C++ to a file opened from OTcl
>Content-Transfer-Encoding: 7bit
>
>Hi all,
>
>how can I write from my C++ code
>to a file that I opened in my OTcl script?
>
>thanks in advance,
>
>niko
Tarik