sex issues

My boyfriend and i been having sex for quite some time now and recently last  week before i  got my period during the time we were having sex i woud get wet at first but then all of a sudden I wouldn't be wet anymore and i would try to continue but it would burn and hurt so we stopped. My period came and it ended yest. And we had sex today and still the same thing keeps happening. Has anyone went through this? What should i do?