VC调用QT的UIDLL

//VC程序
#include "../QTDLL/ExportDll.h" int _tmain(int argc, _TCHAR* argv[]) { printf("%d",add(1)); return 0; }

  

DLL

#include "stdafx.h"
#include "ExportDll.h"
#include "ui_DLG.h"
int add(int a)
{
	QApplication ap(a,NULL);
	QWidget* w  = new QWidget();
	Ui_Form s;  
	s.setupUi(w);
	s.pushButton->winId()

	w->show();
	ap.exec();
	return a+1;

}

  

posted @ 2016-05-24 11:04  ahuo  阅读(567)  评论(0编辑  收藏  举报