A charitable association, corporation or other institution shall file in the office of the Prothonotary of the county in which such injuries shall have occurred a notice in writing, containing the names and addresses of the injured person, the date of the accident, the name and location of the hospital and, if then known, the name of the person alleged to be liable to such injured person by reason of the injuries received, prior to the payment of any moneys to such injured person or his legal representative by such person to such injured person. Copies of the notice shall be sent by registered mail by the hospital to such injured person and all parties in interest who are then known. Thereafter an affidavit by a competent person acting on behalf of such institution, setting forth such service, and all attempts to serve the same shall be filed in the office of the Prothonotary.