Tom's Guide | Tom's Hardware | Tom's Games
![]() |
![]() |
![]() |
Without looking at the lexicals or
any deeper investigation.......another quick and dirty DCL-script
$10:
$ file=f$search("disk:<000000...>*.*;*")
$ if file .eqs. "" then goto 20
$ vn=f$extract(f$locate(";",file)+1,6,file)
$ if vn .lt. 30000 then goto 10
$ write sys$output "''file'"
$ goto 10
$20:
$ exit

Change
vn=f$extract(f$locate(";",file)+1,6,file)
to
vn=f$element(1,";",file)and
Change
write sys$output ""file'"
to
write sys$output fileBut, of course, I'm not one to quibble. :-)

To get version, use F$PARSE:
$ version=f$parse(file,,,"VERSION")
This will hold the separator (";") as well.
To get version without ";":$ version=f$parse(file,,,"VERSION") - ";"
and to get it as a number:
$ version=f$integer(f$parse(file,,,"VERSION") - ";")
Makes it easier to compare:
$ if version .ge. 32000 then ....
Willem Grooters

![]() |
![]() |
![]() |

This post is quite old and has been locked from receiving new replies. Please create a new posting instead.
| Ads by Google |