<div dir="ltr"><div>When i try to open text in textBrowser with command read i got this error message<br><br>def cari(self, event=None):<br><br> #open dialog<br> filename = QtGui.QFileDialog.getOpenFileName(self, 'Open File', '*.xml')<br>
<br> if filename:<br> self.ui.lineFile.delete(0, END)<br> self.ui.lineFile.insert(END, filename)<br><br> #panggil isi data<br> self.isiDataFile(filename)<br><br> def isiDataFile(self, nmfile):<br>
#buka dengan open mode baca<br> teksFile = open(nmfile, 'r').read()<br> <br> self.ui.textFile.delete('1.0', END)<br> self.ui.textFile.insert('1.0', teksFile)<br>
<br>Traceback (most recent call last):<br> File "C:\Users\Mr.Pakde/.qgis2/python/plugins\latih\latihdialog.py", line 44, in cari<br> self.ui.lineFile.delete(0, END)<br><br> 'QLineEdit' object has no attribute 'delete'<br>
<br></div>Can someone help me? <br>I m new in python and QGIS so i dont know what i must do<br><div><br></div></div>