Next year Anny and I will have been married for 25 years.
This is future perfect (see Englishpage.com, USE 2 Duration Before Something in the Future). It is used to show that something will continue up until another action in the future. This sentence describes that next year, you will complete a milestone of 25 years of marriage, which is logically what is implied by the exercise.
Next year Anny and I will be married for 25 years.
This is future progressive, also called future continuous (see Englishpage.com). Future progressive refers only to future events, it doesn't tie in past or present activity. Note that English does not have a future tense, but some forms involving will and shall are labelled as such. See discussion of future forms here.
If someone said this, it would probably be interpreted to mean what is intended in the exercise, but only because that would be the only rational interpretation of its meaning. Technically, though, it would mean something different. It literally means that next year, you will get married and the marriage will then last 25 years.
This is an example of the role that context plays in English. Nobody can predict that a marriage will last 25 years, so the literal meaning wouldn't make sense. Also, English errors and variations are experienced all the time, and the manner in which something is said often conveys more than the actual words. So when a listener hears something, especially something that refers to common aspects of life experience described in commonly used words and phrases, they usually don't parse the words for precise meaning.
They hear the gist of what is said. The word combination might sound odd (dwilbank's answer mentions that 'will be' sounds a little funny to a native English speaker), but people just ignore that and interpret it in the way that makes sense given the context. However, despite the fact that the second sentence would likely be understood, it isn't correct (well more accurately, it is not grammatically correct for the intended meaning and if it is interpreted in a way that is grammatically correct, it doesn't make sense).