Section 164 of Evidence Act "Using, as evidence, of document production of which was refused on notice"
When a party refuses to produce a document which he has had notice to produce, he cannot afterwards use the document as evidence without the consent of the other party or the order of the Court.
Illustration
A use B on an agreement and gives B notice to produce it, At
the trial A calls for the document and B refuses to produce
it. A gives secondary evidence of its contents. B seeks to
produce documents itself to contradict the secondary
evidence given by A, or in order to show that the agreement
is not stamped. He cannot do so.
Section 165 of Evidence Act "Judge's power to put questions or order production"
The Judge may, in order to discover or to obtain proper
proof of relevant facts, ask any question he pleases, in any
form, at any time, of any witness, or of the parties about
any fact relevant of irrelevant; and may order the
production of any document or thing; and neither the parties
nor their agents shall be entitled to make any objection to
any such question or order, nor, without the leave of the
Court, to cross-examine any witness upon any answer give in
reply to any such question:
Provided that the judgment must be based upon facts declared
by this Act to be relevant, and duly proved.
Provided also that this section shall not authorize any
Judge to compel any witness to answer any question or to
produce any document which such witness would be entitled to
refuse to answer or produce under sections 121 to 131, both
inclusive , if the question were asked or the document were
called for by the adverse party; nor shall the Judge ask any
question which it would be improper for any other person to
ask under section 148 or 149; nor shall he dispense with
primary evidence of any document, except in the cases herein
before excepted.