ketest
5th August 2009, 18:32
How do I access the individual strings in a QStringList that was created using getOpenFileNames?
QStringList fileNames;
fileNames = QFileDialog::getOpenFileNames(this,"Select File(s) to search","/home");
// If multiple files names were selected during getOpenFileNames, then how would I print (or access) each one selected?
// I have used getExistingDirectory to get a selected directory and then display it in the textEdit window.
// How can I do the same thing using getOpenFileNames?
QString DirName;
DirName = QFileDialog::getExistingDirectory(this,"Select Folder (Directory) to search in","/home");
ui.textEdit_SearchInFilesFolders->append(DirName);
Thanks,
Kevin
QStringList fileNames;
fileNames = QFileDialog::getOpenFileNames(this,"Select File(s) to search","/home");
// If multiple files names were selected during getOpenFileNames, then how would I print (or access) each one selected?
// I have used getExistingDirectory to get a selected directory and then display it in the textEdit window.
// How can I do the same thing using getOpenFileNames?
QString DirName;
DirName = QFileDialog::getExistingDirectory(this,"Select Folder (Directory) to search in","/home");
ui.textEdit_SearchInFilesFolders->append(DirName);
Thanks,
Kevin