All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
Writing the word divorce is not considered a divorce unless the husband wrote it with the intention of divorce or uttered the word divorce when writing it. Therefore, if you intended to divorce your wife when you wrote the message or you uttered the word divorce, then divorce took place; for more benefit, please refer to Fatwa 89894.
Moreover, according to the view of the majority of the scholars combining the second and third divorce in one wording means that divorce takes place twice.
If we presume that you wanted divorce when you first wrote the message, then your wife becomes irrevocably divorced from you and you cannot take her back unless she marries another man [a true marriage and that man consummates the marriage with her and then he dies or divorces her].
Therefore, it becomes clear that the verse 232 of Chapter Al-Baqarah (Quran 2) does not apply to your case. For more benefit on the kinds of divorce, please refer to Fatwa 82541.
Furthermore, divorcing a pregnant woman is a divorce according to the Sunnah and it takes place as we clarified in Fatwa 82929.
It should be mentioned that the waiting period of a pregnant wife ends as soon as she gives birth to the baby as discussed in Fatwa 84751.
Finally, it should be noted that a husband should avoid hasting to utter the word divorce and he should not make this as a means of solving problems before exhausting all other religious means; for more benefit please refer to Fatwa 85402.
Allaah Knows best.