The 12 is part of the "National Fine & Machine Screw" naming convention.
#2, 4, 5, 6, and so on. There is a National Course and a National Fine thread in this system. Example 10-24 and 10-32.
A number 12 diameter is 0.216" - a 7/32 is 0.2185"
a 12-40 (if you could find one) may fit a 7/32-40
but
a 7/32 -40 likely may not fit a 12-40
*the things we do avoiding work on a snowy day! :D