The sentences (1) and (2) have different meanings.
It is not mandatory the use of negative with "hasta dentro", however, you should use it in sentence (1), if you want to mean that.
I will explain you the difference between both sentences:
- No hay tren hasta dentro de dos horas. (There is no train for two hours)
Explanation: In the following 2 hours, there will not be any train. (After that, there will be some trains)
- Hay trenes hasta dentro de dos horas siguientes. (There are trains for the next two hours)
This is not particularly correct. I would say better: "Hay trenes hasta dentro de dos horas."
Explanation: There will be trains for the next two hours. (After that, there will not be any train)
- Mis amigos no vuelven hasta dentro de una semana.
- Mis amigos vuelven hasta dentro de una semana.
This is the same case, in the first sentence we are saying that the friends will be back in a week time. Nevertheless, in the second sentence, we are saying that my friends will be back in a week, as latest.
You do not need to use the negative with "hasta dentro" as if it was a structure to be memorized. However, depending on the meaning you want to give to the sentence you should use it or not.
We have seen that negative must be used when the event will happen right after the period of time stated in the sentence. Not using the negative, only indicates that the limit time is the stated in the sentence and that the event may happen before.