When I was a child, my sister and I would bring home our bags and our mother combine them, then sort the "bad" pieces out, then split everything into categories - chocolate, hard candy, gum, etc. Then the entire family would sit down and take turns chosing one piece from a specific category, taking turns, until all of the pieces had been chosen, and we'd then move on to the other categories. The idea was that we had to share, because there was no way we were going to eat ten pounds of candy.
You could do a few things...
1- take her only to friends and families houses, and ask them to give her some veggies or fruit, and spent the rest of the time walking around and letting her see all of the people in the costumes.
2 - take her to a few houses, then come home, sort them out, and remove the candy you most don't want for her to have. Then do as my parents did: explain to her that she should share, and allow everyone to pick, one-by-one, a piece of candy or fruit (add in some fruit and veggies to give her the choice of picking them over the candy).
3 - take her trick-or-treating, then sort out the candy and tell her you'll trade her a fruit that is out of season - say, some blueberries or strawberries - for her candy. If that doesn't work, then give her a few pieces, and take the rest to work. At her age, you'll easily be able to tell her that it's "all gone" or that "Daddy ate some, sharing is good, right?"
Hope these suggestions might help!