In self-assembly processes, novel materials or even functional devices can spontaneously build themselves up from simple components. For example, ordered structures of tiny particles and nano-wires can interact with light and electricity in unusual ways: self-assembly of these structures offers a new route to cheap and efficient organic solar cells, or other photonic devices. If the spontaneous assembly of functional materials seems too good to be true, one should bear in mind that many biological structures are formed by self-assembly, and that highly-ordered crystals like ice also assemble themselves during freezing. Building on these examples, artificial self-assembling systems are now becoming possible in the laboratory. However, there are many challenges in designing and developing man-made systems that self-assemble. In particular, one often finds that interactions between particles must be tuned very accurately in order to achieve high-quality assembly. Loosely speaking, the most common results of experiments and computer simulations of self-assembly are either that the particles fail to assemble at all, or that they aggregate into a disordered clump (this is known as kinetic trapping). Effective self-assembly sits on a knife-edge between these regimes: particles must interact strongly enough to make assembly possible, but interactions must also be weak enough that disordered aggregates do not dominate the system. Here, we propose to consider how this problem can be avoided if interactions between particles can be varied with time. This is increasingly becoming possible in experimental colloidal systems, which are ideal for self-assembly because they involve microscopic particles whose interactions are well-understood and can therefore be controlled and designed. However, we do not yet know time-dependent interactions should be exploited in these systems, in order to arrive at any specific result. We will address this question using theory and computer simulation. We will investigate how time-dependent interactions can be exploited in self-assembly of different kinds of crystal, using colloidal particles. We will also consider colloidal gels, which sometimes interfere with crystallisation, but are also industrially-relevant materials in their own right. By considering several experimentally-relevant systems and a range of protocols for controlling interactions, we aim to arrive at general "design rules" for these self-assembly processes, showing how time-dependent interactions may be used to control and optimise the production of different kinds of ordered state.