It shall be the duty of every laborer claiming a preference under this act, by himself, his agent or attorney, to give notice in writing of the amount of his claim, before the sale, to the executors, administrators, assignee, sheriff or other officer whose duty it shall be to sell said saw-logs, otherwise his claim shall not be preferred under this act.
43 P.S. § 227