What should I do now when this conference first sends me an "accept", then a "reject"? A little while back I had sent one of my works to an ACM conference -just a National level conference. I knew my work was not one of the best they were going to receive, but given the quality of the papers published in the conference in the previous years, I was almost sure of an "Accept", and sure enough, an "Accept" did arrive around a week ago. But reviewer practically tore my work to pieces, saying that the claim is not novel, the data sets are biased, etc. And I do agree with him on most of the points. 

Since the reviewer had given a detailed review, I had been working all week long to improve the quality of the paper and address all the points mentioned by him. 

But to my great surprise, today I receive a mail from the PC chairs stating -


  we had inadvertently sent an ACCEPT for your paper. After discussion with reviewers we have decided to not accept this paper. 


This is, to say the least, unethical unprofessional. And my entire week of hard work in improving the paper just went down the drain I guess.

My questions here-


Should I put any endeavor in contacting the PC Chairs and ask them to explain this strange stand? Should I explain my stand that the work has been drastically changed and improved from what it was when submitted?
Does such a behavior make them accountable for any legal action from my side? And, is it worth for me to take such an action?


UPDATE:
Thank you all for your comments and answers. Posting this here just to make the story complete. My guide insisted that we should write to the PC chair, requesting an opportunity to resubmit since some of the previous review comments were not really justified and too harsh on us, and anyways our paper stands improved from what it was before.

So we did re-submit. And our improved paper was accepted as well! Rather having an unsatisfactory publication, I have a better paper at hand now!

So happy ending after all :)
Should I put any endeavor in contacting the PC Chairs and ask them to explain this strange stand? Should I explain my stand that the work has been drastically changed and improved from what it was when submitted?


I think an email to the PC would be appropriate.  Don't expect the answer to change, however, and it may very well have been an administrative oversight.  Even as a mistake, it is a relatively minor one that you don't have much control over.


  Does such a behavior make them accountable for any legal action from my side? And, is it worth for me to take such an action?


No. Their decisions aren't bound by any laws (that I know of) that could force them to honor their original email.  If you make a big deal of it, you're likely to make a bad name for yourself, regardless of the mistake being on their end.

In the end, you've now got a better paper that probably shouldn't have been published anyway.  Your changes are now in place, and you admit to having improved it.  Submit it to another conference, and move on.