Your hload & hsave commands won't work, as they only support a single table name & file.
For your hfree, you might consider /hfree -w Table*
That will free all tables that start with Table
I don't know if that is accurate for your real table names, but it should give you the idea.
Here's one possiblity (based on what you've shown)
alias hash-refresh {
hfree -w Table*
var %a = 1, %b = 3
while %a <= %b {
hmake $+(Table,%a) $iif(%a = 1,500,$iif(%a = 2,300,100))
hload $+(Table,%a) $+(txtfile,%a,.txt)
hsave $+(Table,%a) $+(Table,%a,.hsh)
inc %a
}
}
As you should be able to tell, this isn't going to save you much in coding space with only 3 tables, and the names of the tables & files are strictly based on what you've given.
If you've just substituted Table and txtfile for the actual names, then what I've written may not work for you.