The cross-helicity integral is known in fluid dynamics and plasma physics as a topological invariant which measures the mutual linkage of two divergence-free vector fields, e.g., magnetic fields, on a three-dimensional domain. Generalizing this concept, a new topological invariant is found which measures the mutual linkage of three closed two-forms, e.g., electromagnetic fields, on a four-dimensional domain. The integral is shown to detect a separation of the cross helicity between two of the fields with the help of the third field. It can be related to the triple linking number known in knot theory. Furthermore, it is shown that the well-known three-dimensional cross helicity and the new four-dimensional invariant are the first two examples of a series of topological invariants which are defined by [Formula presented] field strengths [Formula presented] on a simply connected [Formula presented]-dimensional manifold [Formula presented].