Ok, I'll start the ball rolling. But I am no expert in these matters, but I think a little more info is required before anyone can assist.
Can you confirm what type of visa you are applying for - I'm assuming settlement?
How old is your step-daughter?
From what age and for how long has your wife lived apart from her daughter?
I think it would be better if you could copy here - with all personal identifiers removed - the written reason for refusal.
Joint custody? You don't mean with the father so I believe the Embassy want absolute assurances that your wife was actually in complete control of your step-daughter, with the grandparents acting on her instructions re: schooling, welfare etc as well as paying for her upkeep. Do you have any evidence of this?
From what you have written, I'm assuming you have covered the fathers involvement / absence?
I'll bow out now and allow those more knowledgeable to assist. Good luck!