Hai all,
I am new to qt. I want to open a dialog box . I created the dialog using form designer. But when i try to create a object to it , it shows an error

/home/bharani/browser/mainwindow.cpp:258: error: variable ‘Ui:ialog d’ has initializer but incomplete type

After googling a found that the error is duo to missing header file. I have added both
dialog.h and qdialog to the mainwindow.cpp file. But the error is still there.

mainwindow.cpp file is

#include <QtGui>
#include <QtWebKit>
#include "mainwindow.h"
#include <QtDebug>
#include <QDialog>
#include "dialog.h"

void MainWindow:penPreferences()
{
Ui:ialog d(this); //error
}

Any body tell me what i am missing here.
Thanks .