untitled
viviti

ValueDiff  

What is ValueDiff?

ValueDiff is a decision program. The program checks the specified location in side the test file, It makes sure that DO the value is bigger than the defined margin or not, bigger means alarm and not bigger means normal. In case of the value is bigger than the defined margin, parameter of Err-Proc will be submited. The compare resault will be saved in log file. In case of the status is return to normal , parameter of Ret-Proc will be submited. Inverse parameter will make the resualt inverse, means bigger is normal and not bigger is alarm status.

For two files compare case, the program will compare the same locations of the two files.First line and word No. was defined by parameters W and L, and every loop the line number will add by one. The program will copy file1 to file2 before exit.

Err-Proc and Ret-Proc must executable. For normal case, Err-Proc will be submited only first time the status changes from normal to alarm. In case of Ret-Proc was defined as -1, means submited Err-Proc evey time while alarm was happened.


How to use ValueDiff?     goto top

The standard manner used to invoke is:

ValueDiff [i|I] v|V=value d|D=XX l|L=Line-No. w|W=Word-No compare-file Err-Proc Ret-Proc [Log-file]

for one file with value compare.

ValueDiff [i|I] d|D=XX l|L=Line-No. w|W=Word-No x|X=YY compare-file-1 compare-file-2 Err-Proc Ret-Proc [Log-file]

for two files compare.


i|I Set inverse alarm condition. Means same text value will submit Err-Proc.

v|V=value The value for Compare. In normal case, if compare value is bigger than the defined margin XX, Err-Proc will be submitted.

d|D=XX defined margin XX

l|L LIne-No.Define the first line number of where the compare text of the compare file.

w|W Word-No Define the Word number of Line-No of where the compare text of the compare file.

x|X=YY define the do loop counter for two files compare. (start to compare for two files mode and loop YY times.[line number will auto inc. by one])

Log-file Log the informations for keep last status. default name is VDiff.log if Ret-Proc = -1 means in case of alarm was found Err-Proc will submited all the time. In case of compare-file-2 was present compare-file-1 will copy to compare-file-2 before exit the program.

Return Value:
0 Normal
-1 Return to Normal
1 First Alarm
2 Continue Alarm
5 Error return

*** Return Value can be checks by ERRORLEVEL parameter for batch IF statement.





Web Hosting · Blog · Guestbooks · Message Forums · Mailing Lists
Easiest Website Builder ever! · Build your own toolbar · Free Talking Character · Email Marketing
powered by a free webtools company bravenet.com