1
/****************************************************************************
2
** ui.h extension file, included from the uic-generated form implementation.
4
** If you wish to add, delete or rename functions or slots use
5
** Qt Designer which will update this file, preserving your code. Create an
6
** init() function in place of a constructor, and a destroy() function in
7
** place of a destructor.
8
*****************************************************************************/
11
#include <qmessagebox.h>
15
MReportViewer* rptviewer = new MReportViewer(this);
17
setCentralWidget(rptviewer);
19
QFile f("sample3.kud");
21
if (f.open(IO_ReadOnly))
23
if (!rptviewer -> setReportData(&f))
24
QMessageBox::warning(this,"",tr("Invalid data file: %1").arg("sample1.kud"));
29
QMessageBox::warning(this,"",tr("Unable to open data file: %1").arg("sample1.kud"));
31
QFile ff("sample3.kut");
33
if (ff.open(IO_ReadOnly))
35
if (!rptviewer -> setReportTemplate(&ff))
36
QMessageBox::warning(this,"",tr("Invalid data file: %1").arg("sample1.kut"));
41
QMessageBox::warning(this,"",tr("Unable to open data file: %1").arg("sample1.kud"));
43
rptviewer->renderReport();
52
void Form1::fileOpen()
57
void Form1::fileSave()
62
void Form1::fileSaveAs()
67
void Form1::filePrint()
72
void Form1::fileExit()
77
void Form1::editUndo()
82
void Form1::editRedo()
92
void Form1::editCopy()
97
void Form1::editPaste()
102
void Form1::editFind()
107
void Form1::helpIndex()
112
void Form1::helpContents()
117
void Form1::helpAbout()
122
void Form1::destroy()