Welcome, Guest. Please login or register.
Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Ender X

Pages: [1]
1
Discussion | Обсуждение / Re: Вопросы новичка
« on: September 07, 2018, 03:15:53 PM »
Ender X, ты уверен, что по заданному пути точно есть твой шаблон отчета?
Если он лежит рядом с исполняшкой (exe файлом), укажи явно

report->loadFromFile(qApp->applicationDriPath()+"/report.lrxml");

Спасибо! Помогло.  :)

2
Discussion | Обсуждение / Re: Вопросы новичка
« on: September 07, 2018, 12:34:51 PM »
День добрый.

Есть заполненная QStandardItemModel.

По коду:
Code: [Select]
report = new LimeReport::ReportEngine(this);
    report->dataManager()->addModel("model", model, true);
    report->designReport();
исправно выводит дизайнер отчёта.

А вот по коду:
Code: [Select]
report = new LimeReport::ReportEngine(this);
    report->dataManager()->addModel("model", model, true);
    report->loadFromFile("report.lrxml");
    report->previewReport();
открывается только виджет, предпросмотра готового отчёта не видать.

Что я делаю не так?

P.S. report->printReport() показывает окно настройки печати.

Win 7 Pro Rus
Qt Creator 4.6.2
Qt 5.11.1

Pages: [1]