Include File Parameter

Subhransu

Member
Hi All,
I want to write a program which will list all the .p programs which have a specific include file (.i) with a specific include parameter (e.g. &filename). Can anyone suggest any simple ways to do so with a sample code?

Appriciate your help on this.

Thanks.
Subhransu
 

skunal

Member
Are u using the Windows or Unix platform. I guess if ur using UNIX platform you can Write the Shell script todo this task in more simpler way just by using the UNIX commands like grep and all....
 
input from value (file-name)
repeat:
import unformatted line.
if line matches ("*{" + inclideFileName + "*" + "&filename" + "}*") then
message "Found! " file-name view-as alert-box.
end.
input close.
 

tamhas

ProgressTalk.com Sponsor
Doing this with grep-like tools is dangerous. E.g., xx/xxxx/xxxxxxxx.i looks the same in Windows as XX/XXXX/XXXXXXXX.i but is a lot more work to find using grep. Likewise,

{ xx/xxxx/xxxxx.i &filename }

and

{ xx/xxxx/xxxxx.i
&filename
}

are functionally equivalent, but hard to find using grep and similar tools.

The best solution is to do some scripting with the ProParse engine used by ProLint.
 
Top