This is not especially difficult for an Assembler programmer. I would read the entire directory, save the members you want to update, then, for each member you're updating, do a STOW with the replace option with the ISPF stats as user data. There are a few gotchas here:
- I don't think the format of ISPF user data is formally documented anywhere. I have it, but it's not real handy.
- ISPF user data adds 30 bytes to each directory entry. It's quite easy to fill up the directory before you've updated all your members.
The proposal to write an edit macro to save each member will fill up the space and possibly give you x37 type ABENDs before you finish.
I would not do my directory updates as I'm reading the directory.