Orach Chaim 422:1 mentions that one who forgets Yaale V'Yavo at Maariv does not have to Daven again since we do not do Kiddush HaChodesh at night. However if one forgot at Shacharis or Mincha he does have to Daven again. This coming month Sivan 5773 the Molad is at 7:49 AM and 16 Chalakim on the actual day of Rosh Chodesh. If one Davens Shacharis at 6 AM prior to the Molad and forgot Yaale V'Yavo would they be required to Daven again since it is during the day or perhaps not since it would not have been Rosh Chodesh yet since it is prior to the Molad?
It doesn't seem that there is a connection between the Molad and the sanctification of the month during the day.
The Talmud in Sanhedrin (11b) relates the following:
ת"ר אין מעברין את השנה אלא ביום ואם עיברוה בלילה אינה מעוברת ואין מקדשין את החדש אלא ביום ואם קידשוהו בלילה אינו מקודש א"ר אבא מאי קרא תקעו בחדש שופר בכסה ליום חגנו איזהו חג שהחדש מתכסה בו הוי אומר זה ראש השנה וכתיב כי חוק לישראל הוא משפט לאלהי יעקב מה משפט ביום אף קידוש החדש ביום
Our Rabbis taught: A leap-year is to be declared only by day, and if it has been declared by night, the declaration is invalid. The sanctification of a month is to be performed by day, and if it has been performed by night it is not valid. R. Abba says: What passage [proves this]? — Blow the horn at the new moon, at the covering of the moon our feast-day. Now on which feast is the moon covered? — We must say on the New Year. And it is thereupon written, For this is a statute for Israel, a judgment of the God of Jacob: Just as judgment is executed by day, so also must the sanctification of the month take place by day.
Based on this, it would seem that the need to sanctify the month during the day is unrelated to the appearance of the molad and therefore according to the reasoning of the Shulchan Aruch that you quoted one would be required to repeat shmoneh esrai if one forgot to insert ya'aleh ve'yavoh even if one originally said it prior to the appearance of the molad.