It is difficult for grandparents, or any third party, to get custody of children when there is a parent alive who contests the move. However, your daughter's troubles do give rise to the potential that you could accomplish this. It would, in all likelihood, require the assistance of an attorney because the threshold you have to overcome is establishing that the parent is unfit and that it is in the best interests of the children for custody to lie elsewhere. Good luck!
I do not practice law in MD so I can only state what I know from New Jersey. The two routes I am aware of here would be to file a custody petition as mentioned by the other attorney. The other, which has its risks, is to alert your state's child protection agency as to the dangers you suspect your daughter is placing your grandchild in. The problem with that, is that although child welfare agencies are usually tasked with finding close relatives to place a child in before placing a child in a foster home, there is no guarantee. However, they would probably have to look into you if they decided removal was necessary. And, on the other hand, if they didn't feel removal was required, they may require your daughter to participate in services to ensure the safety of the grandchildren.
DISCLAIMER: This communication does not create an attorney-client relationship and is not legal advice unless you have entered into a fee agreement with the Law Office of Anthony J. Van Zwaren, P.C. and have paid the required fees. The information contained in this email may be privileged. Dissemination, distribution or copying of this e-mail or the information contained within it by anyone other than the intended recipient is prohibited. If you are not the intended recipient, please delete this message and any attachments from your system and notify us.