Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!
  • Students Click Here

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here


How to handle "tcflush"

How to handle "tcflush"

How to handle "tcflush"


I have a 4GL program which expecting 2 input screens.

The 1st screen is expecting:
1. date1
2. date2

The 2nd screen is expecting:
1. input array of a/c no and press F8 to process
2. Leave the entry blank and press F8 to process.

I have a unix scripts which calling this 4GL program by passing all the stdin as below using echo command:

ksh -c "echo 31/08/2005 31/08/2005^M^M$(tput kf8)|/proj/prog.exe" <<!

However, the problem occured while I execute this command and it stopped at the 2nd screen whereby the 4GL program
was calling the tcflush function before the input array.

I have tried commented the calling function of TCIFLUSH in my 4GL program, and my script is working totally fine. However, my boss has given the instruction not to modify any 4GL program. So, anyone has any clue to resolve

Is there anywhere to include a "pause" in the ksh command before the 2nd parameters being pass to the 4gl program from unix script?


ksh -c "echo 31/08/2005 31/08/2005^M^M  <anywhere to include a Pause in between here >  $(tput kf8)|/proj/prog.exe" <<!


Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close