Given a code C, invariant linear forms are used to study the designs afforded by codewords of a fixed weight. The most important theorem relating codes and designs is due to Assmus and Mattson [J. Combin. Theory, 6 (1969), pp. 122-1511, and this theorem is extended in different ways. For extremal self dual codes over the fields F2 and F3, it is proved that the t-designs afforded by the codewords of any fixed weight exhibit extra regularity with respect to (t + 2)-sets. The same is true for the design afforded by the codewords of minimum weight in an extremal self-dual code over F4. The invariant linear forms are also used to construct Boolean designs with several block sizes, extending previous work by Safavi-Naini and Blake [Utilitas Math....