When bond has been executed by the plaintiff or defendant for the forthcoming of the property in contest, the value of the property, and the damages resulting from its detention must be assessed by the court or jury trying the contest. If the unsuccessful party fails for 20 days after judgment to deliver the property and pay the damages as required by the condition of the bond, it shall be the duty of the sheriff to make due return of that fact; and, upon such return being made, the bond shall have the force and effect of a judgment, and execution may issue thereon against the obligors on the bond for the value of the property and the damages assessed, or either, and costs.