I would like to ask regarding the guidance of Imam. In each time, every ummah met the imam of their time and were able to be guided by the Imam of their time. How about this ummah since our imam is in ghaibah , there are those that died without the guidance of the Imam of their time. My question is will they be allowed to be among the soldiers of Imam, and that they will be guided again or?

Not everyone in past met Imam of their time but they received guidance from Imam through different channels. So we are receiving guidance.
And those who really spent their lives as Imam e Zaman ajtf wants, they will back at the reappearance of the Imam inshaAllah.
Therefore it is recommended to recite dua e Ahad 40 days continuosly after Fajar prayer.