Altium Designer - Database library - Parameter: Component Type
ComponentType = 'Standard' or 'Standard (No BOM)' works perfectly fine in SCH Filter to highlight those components my end and as such should be the right thing to set/get for your purpose.

Are you encoding/typing/what-evering the string value correctly? Altium is very persnickety with string types. (For one example in SCH Filter "Standard" would give an error, but 'Standard' works fine) 

See also: Altium TechDocs on ComponentType