It is narrated from Sayyiduna Hakim bin Hizam (may Allah be pleased with him) that he asked the Prophet (peace and blessings of Allah be upon him): O Messenger of Allah! What do you say about those deeds which I used to do as acts of worship in the days of ignorance, such as maintaining ties of kinship, freeing slaves, and giving charity? Will I receive reward for them? Hakim says that the Messenger of Allah (peace and blessings of Allah be upon him) said: "You have accepted Islam along with your previous good deeds."
Hadith Referenceالادب المفرد / كتاب صلة الرحم / 70
Hadith Gradingالألبانی:صحیح
Hadith Takhrij«صحيح : أخرجه البخاري ، كتاب البيوع ، باب شراء المملوك من الحربي و هبته و عتقه : 2220 و مسلم : 123 - الصحيحة : 248»