Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

VS 2015 QT5.6.0 QFileDialog::GetSaveFileName API issue



  • We have files names like attached image.
    We would like to list out them when we save it. So we use the filter * . slb*. But the default name in QT5.6.0 is shown as Database1.slb*. But in QT4.7.3, it is Database1(with out extension)

    getSaveFileName(QWidget *parent = Q_NULLPTR,
    const QString &caption = QString(),
    const QString &dir = QString(),
    const QString &filter = QString(),
    QString *selectedFilter = Q_NULLPTR,
    Options options = Options());

    caption - "Database(*.slb *)"

    filename = QFileDialog::getSaveFileName("Save As", strHomeDir, "Database( * .slb * )", &selectedfilter) ;
    But with QT5.6.0, * it is considering as some special symbol and not saving as the default name is Database1.slb*
    Do you have a fix for it?![fileextensions.png](https://ddgobkiprc33d.cloudfront.net/e8639667-4e09-4e23-a7f0-8174b3aed069.png


Log in to reply