When my grandparents still lived in the area, we would go visit them a couple of times a month. They had discovered that my kids liked hot dogs and mac-a-roni and cheese. And potato chips... and cookies... and soda (not the diet kind usually)... and candy... and ice cream. So of course they were always offering these things when we visited. It was at that time that I determined to never let my weight loss become more important than my manners.
Since there was nothing being offered to eat that was remotely weight conscious, I ate what they served and tried to limit it some but not to the point of being rude. I would at least eat one cookie. To not eat what they offered would possibly make them think I didn't like it. To tell them that I was dieting would probably stress them out.
These kind of occasions will present themselves occasionally. People are always more important and there are ways of making up for it later and trying to eat carefully when faced with this type of situation. Please put your respect for people over your weight loss goals.