Reading the contents of a .out file

Shubham Pipada

New Member
Hello all,
My question is that I have a .out file generated through Cim program. In my Cim program i am just checking the .out file by opening it to check if there are any errors(I know .out should not actually have any errors but still). So i use the following :
DEFINE VARIABLE lvc_error AS CHARACTER FORMAT "x(76)".
INPUT FROM value ("/ext3/home/x.out").
import unformatted lvc_error.
if lvc_error begins "Error" or lvc_error begins "Invalid"
or lvc_error begins "**" OR lvc_error BEGINS "unable to update" OR lvc_error
BEGINS "File"
then do:
DISPLAY lvc_error WITH DOWN FRAME x.
DOWN WITH FRAME x NO-LABELS.
END.
INPUT CLOSE.
The .out does contain the error of unable to update the database field. So as per the above query, it should work ideally. But it doesnt work.
So it would be great if anyone could help with this.
Also i read about the "contains" function.....but it works only on word indexed tables. So isnt there any function/way to read a file that contains certain text?

Thanks in advance.
 

Stefan

Active Member
Code:
matches
 
Top