import xml.etree.ElementTree as ET


def extract_book_content_from_file(file_path):
    file = open(file_path, 'r')
    xml_content = file.read()
    file.close()
    root = ET.fromstring(xml_content)
    book_contents = []
    for reading_data_item in root.findall('.//ReadingDataItem'):
        book_content = reading_data_item.find('BookContent').text
        if book_content:
            book_contents.append(book_content)
    for index, content in enumerate(book_contents, 1):
        print "%d. %s" % (index, content)


if __name__ == '__main__':
    file_path = "C:\\Users\\edy\\Desktop\\dkx.xml"
    extract_book_content_from_file(file_path)
