Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
How to create File dialog with Tree view?
mathi77in last edited by
Tree view directory selection dialog use following code @QFileDialog::getExistingDirectory(this, tr("Open Directory"),
But This dialog was display in center of the PC manitor. So i write Qfiledialog class with treeview option
QFileSystemModel *model = new QFileSystemModel(this);
model->setResolveSymlinks(true);QTreeView *tree = new QTreeView();
i select directory on File dialog box. But File dialog box have display from Tree view style.
Woody last edited by
Have you looked into it yourself?
I don't really know what you mean. Do you want a list of directories in a QTreeView?
Sam last edited by
If can look int "QDirModel":http://qt-project.org/doc/qt-4.8/qdirmodel.html#details and "QFileSystemModel":http://qt-project.org/doc/qt-4.8/qfilesystemmodel.html examples. But your question is still not clear what exactly is your requirement. If you have implemented some code then kindly provide it so that it will be more clear for us to understand .
EDIT: Thanks for the code previously it was just displaying "KK"