Thank you for your query on Healthcare Magic.
Your child seems to have acute gastroenteritis as there is stomach pain followed by an episode of loose stool
It is looking like a viral gastroenteritis
Maintain her hydration by giving sips of oral rehydration solutions like Pedialyte
is not helpful for this condition and rather it will worsen the situation by causing increase in loose stools.
Physical examination by the doctor is needed to assess her hydration status, examination of her abdomen and the treatment.
Hope I have answered your query.