Here we will see Section 7 of The Indian Evidence Act.
Facts which are the occasion, cause or effect of facts in issue : Facts which are the occasion, cause or effect, immediate or otherwise, of relevant facts, or facts in issue, or which constitute the state of things under which they happened, or which afforded an opportunity for their occurrence or transaction, are relevant.
(a) The question is, whether A robbed B.
The facts that, shortly before the robbery, B went to a fair with money in his possession, and that he showed it, or mentioned the fact that he had it, to third persons, are relevant.
(b) The question is, whether A murdered B.
Marks on the ground, produced by a struggle at or near the place where the murder was committed, are relevant facts.
(c) The question is, whether A poisoned B.
The state of B’s health before the symptoms ascribed to poison, and habits of B, known to A, which afforded an opportunity for the administration of poison, are relevant facts.