Read this:
http://wiki.hydrogenaud.io/index.php?title=Foobar2000:Title_Formatting_Reference
Check if path contains 'VA-' (will evaluate true or false):
$strstr(%path%,VA-)
Check if path contains 'VA-' OR 'VA - ':
$or($strstr(%path%,VA-),$strstr(%path%,VA - ))
Wrap it inside an $if() function to decide what happens if it evaluates true or false:
$if($or($strstr(%path%,VA-),$strstr(%path%,VA - )),TRUE,FALSE)
Show %album% only if it the statement evaluated true:
$if($or($strstr(%path%,VA-),$strstr(%path%,VA - )),%album%,)
You may opt to substitute this for the first code in my post:
$strstr($directory(%path%,1),VA-)
It ensures that the matches are folders and also that they are exactly N level above the current track by swapping '%path%' with '$directory(%path%,1)'. Currently N is 1, which means the same folder as the file resides in. 2 would mean 2 levels above and so on. If you have variable directory structure this obviously won't work.