A pregnant woman intended to dedicate her newborn to Allah Almighty if she gave birth to a male. By this intention, she meant to enroll the son at Al-Azhar so as to receive an Islamic education. However, she later forgot this, and he joined another educational institution. Is this considered a vow? What is the due expiation in this case?
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, sallallaahu ‘alayhi wa sallam, is His slave and Messenger.
A mere intention to make a vow is not considered a vow. For the vow to be valid, it is a prerequisite that the person says the specific formula of a vow. It was narrated on the authority of Abu Hurayrah that the Messenger of Allaah, sallallaahu ‘alayhi wa sallam, said: "Allaah has forgiven my community for what crosses their minds as long as they do not act upon it or speak of it." [Al-Bukhari and Muslim]
Commenting on the Hadeeth, Al-Kirmani said: "The Hadeeth means that just having thoughts does not count. Rather, uttering words and doing acts is what counts concerning the statements and actions for which the person is held accountable."
This is to be more stressed when one suffers from (devilish) whispers.
The following is stated in Al-Mawsoo‘ah Al-Fiqhiyyah:
The effect of the formula is its consequent rulings. It is the original purpose of saying the statement. The formula expresses the commitment one obliges himself to observe towards other people, such as contracts of sale; leasing; reconciliation or marriage; a commitment towards Allaah Almighty, such as making vows; and saying Thikr (remembrance of Allaah). Also, it expresses the rights that one owes to others or the rights due to him by others, such as attestations.
Consequently, what is mentioned in the question is not considered, a vow and the woman is not required to do anything.
Allaah Knows best.
You can search for fatwa through many choices