I've programmatically using text manipulation created solution files for .vcproj files (but cs/vb would work just the same). It isn't really hard to figure out how to do it if you open up a solution file in notepad or whatever.
Unfortunately I cannot provide the code as it is proprietary.