Method and apparatus for forming structural members