If you are using an FHA or conventional financing to buy the property, chances are you can not get a loan without running water prior to closing.
First of all, utilities should be up and running for the home inspection and appraisal.
However, there are instances when you can close even if the water is turned off on a 203k loan.
I can't answer the question regarding the realtor's action for lack of details or information.
I hope this answer helps.
Best of Luck.