Jump to content

Using CRT unit shuts down redirection and pipelines

- - - - -

This topic has been archived. This means that you cannot reply to this topic.
1 reply to this topic

#1
Actor

Actor

    Newbie

  • Members
  • PipPip
  • 24 posts
Why?

Is there a way to use CTR and recover redirection and pipelines?

#2
Firebird_38

Firebird_38

    Programmer

  • Members
  • PipPipPipPip
  • 126 posts
Yes, there is.
But if you're using CRT on a modern system, you get very weird errors, because, well, it has to do with your processor being way too fast.

Anyway, there's a way to do that.

Crt chops off the original DOS file access, because just writing to the screen is MUCH faster.

assign(output, '');
rewrite(output);
assign(input,'');
reset(input);

You can also set it back:
AssignCrt(input);
reset(input);
AssignCrt(output);
rewrite(output);

Good luck

Posted Image