2014-03-28 101 views

回答

0
def fetchpnum(self,searchable): 
     # print self.doc1.Paragraphs.Count 
     for i in range(1, self.doc1.Paragraphs.Count): 
      value = self.doc1.Paragraphs(i).Range.Text.lower() 
      if value.startswith(searchable.lower()): 
       return i 
     return 0