# how to clear the screen

**URL:** <https://techcommunity.softwareag.com/t/how-to-clear-the-screen/186454>\
**Category:** Forum\
**Tags:** Adabas-Natural, Natural, Natural-Code-Samples, Natural-on-Windows-Unix\
**Created:** [January 26, 2016, 10:24am UTC](https://techcommunity.softwareag.com/t/how-to-clear-the-screen/186454 "2016-01-26T10:24:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mister\_Ramon](https://avatars.discourse-cdn.com/v4/letter/m/c37758/32.png) [@Mister\_Ramon](https://techcommunity.softwareag.com/u/Mister_Ramon)\
**Post date:** [January 26, 2016, 10:24am UTC](https://techcommunity.softwareag.com/t/how-to-clear-the-screen/186454/1 "2016-01-26T10:24:46Z")

</div>

hi all.  
i’ve a new question. i dont know if it is possible.  
in this program, after the first research, when it ask for second research, i’ve the screen with the data of first research.

```auto

0010 DEFINE DATA LOCAL
0020 1 EMPLOYEES VIEW OF EMPLOYEES
0030 2 PERSONNEL-ID (A8)
0040 2 FULL-NAME
0050 3 FIRST-NAME (A20)
0060 3 NAME (A20)
0070 1 #NAME (A20)
0080 END-DEFINE
0090 *
0100 DEFINE WINDOW W1
0110 SIZE 10*40
0120 BASE 10/40
0130 DEFINE WINDOW W2
0140 SIZE 4*40
0150 BASE 14/50
0160 *  
0170 REPEAT
0180 INPUT WINDOW='W1' / 'INSERT THE NAME ' #NAME
0190 FIND EMPLOYEES WITH NAME=#NAME
0200 IF NO RECORDS FOUND
0210 INPUT WINDOW='W2' / 'NO RECORDS FOUND'
0220 ESCAPE BOTTOM
0230 END-NOREC
0240 DISPLAY EMPLOYEES
0250 END-FIND
0260 *
0270 END-REPEAT
0280 END
```

result in attachment.  
how can i clear the screen after press the ENTER key?

thank you

![IMG.JPG](https://global.discourse-cdn.com/techcommunity/original/2X/4/4e8cb92fb6d2400478f05b65d4308c20af8e76d5.jpeg)

---

<div class="post-metadata">

**Author:** ![Steve\_Robinson](https://sea1.discourse-cdn.com/techcommunity/user_avatar/techcommunity.softwareag.com/steve_robinson/32/107_2.png) [@Steve\_Robinson](https://techcommunity.softwareag.com/u/Steve_Robinson)\
**Post date:** [January 26, 2016, 1:37pm UTC](https://techcommunity.softwareag.com/t/how-to-clear-the-screen/186454/2 "2016-01-26T13:37:54Z")

</div>

The simplest solutions are sometimes the best.

```
 Get rid of window W1. If you want you can "draw" something like a window. For example,
 something like INPUT 8/5 '*' (40) 10/7 'insert the name' #name 12/5 '*' (40). You can make this prettier
 by adding asterisks to present vertical members to a box out of asterisks. This would replace line 0180
 in your code. You could also use color to create lines that would look like a window. For example, you could  
 have an A40 field called #BLANKS that is blank. Then, instead of

INPUT 8/5 '*' (40) you would have INPUT 8/5 #BLANKS (AD=OV CD=PI)

```

There are other solutions possible, but none I can see that are as simple.

For example, You could have something like:

FIND EMPLOYEES WITH NAME = #NAME  
ADD 1 to #COUNT  
MOVE EMPLOYEES TO #EMP (#COUNT)  
END-FIND

Then DISPLAY #EMP array with blank lines to fill the last page.

Other solutions would involve playing with %N, %Q. I have not played with these since they would definitely be messy.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/techcommunity/original/3X/c/d/cd19967bb605d28a72d77eb83a1cae22f3df2eb8.svg) [@system](https://techcommunity.softwareag.com/u/system)\
**Post date:** [April 2, 2021, 3:35pm UTC](https://techcommunity.softwareag.com/t/how-to-clear-the-screen/186454/3 "2021-04-02T15:35:13Z")

</div>


