Section 340. If the creditor declares to the debtor an intention to release the obligation, it is extinguished.
Section 341. If two persons are bound to each other by obligations whose subject is of the same kind and both of which are due, either debtor may be discharged from his obligation by set-off to the extent to which the amounts of the obligations correspond, unless the nature of one of the obligations does not admit of it.
The provisions of the foregoing paragraph do not apply, if the parties have declared a contrary intention; but such intention cannot be set up against a third person acting in good faith.
Section 342. Set-off is made by a declaration of intention by one party to another. A condition or time commencement or ending cannot be added to such declaration.
The declaration of intention mentioned in the foregoing paragraph relates back in its effect to the time when both obligations could first have been set-off.
Section 343. A set-off may be made even though the place of performance of the two obligations is different; but the party who makes the set-off must indemnify the other party for any damage caused thereby.
Section 344. A claim against which there is a defense may not be set-off. Prescription does not exclude set-off, if the claim barred by prescription was not barred at the time at which it could have been set-off against the other claim.
Section 345. If an obligation arises from an unlawful act, the debtor cannot avail himself of a set-off against the creditor.
Section 346. If a claim is not subject to judicial attachment, it is not subject to set-off.
Section 347. A third debtor who has received from the Court an order of prohibition of payment cannot set up against the seizing creditor an obligation subsequently acquired by him.
Section 348. If either party has several claims suitable for set-off, the party making the set-off may specify the claims which are to be set-off against each other. If the set-off is declared without such specification, or if the other party objects without delay, provisions of Section 328 paragraph 2 apply mutatis mutandis.
If the party making the set-off owes the other party interest and costs in addition to the principal performance, the provisions of Section 329 apply mutatis mutandis.