Hi everyone.I had to make a dll from my current source to use in C#.I did it with QAxfactory and Qt 4.8.6 and made a dll and used in C# but when I set target build to 64 bit in vs studio my C# program cannot start because my dll(that I have built from my qt source) was 32 bit.I compiled my qt program 64 bit and made 64 bit dll but when I want to add it as COM component(I register it with Regsvr32.exe) it gives me this error :Self registration for d:\.......dll faild.I compiled it with qt 5.2.1 and the result was the same.What should I do???
#ifndef OBJECTS_H
#define OBJECTS_H
#include <QWidget>
#include <QColor>
QT_BEGIN_NAMESPACE
QT_END_NAMESPACE
class QSubWidget;
class CirclesGraphicsScene;
class CirclesGraphicsView;
//! [0]
{
Q_OBJECT
Q_CLASSINFO("ClassID", "{d574a747-8016-46db-a07c-b2b4854ee75c}")
Q_CLASSINFO("InterfaceID", "{4a30719d-d9c2-4659-9d16-67378209f822}")
Q_CLASSINFO("EventsID", "{4a30719d-d9c2-4659-9d16-67378209f823}")
Q_PROPERTY(QColor backgroundColor READ backgroundColor WRITE setBackgroundColor
) Q_PROPERTY(int circleNumber READ circleNumber WRITE setCircleNumber)
void createScene();
public:
QColor backgroundColor
()const;
int circleNumber()const{return _n;}
public slots:
//--general
void setBackgroundColor
(QColor color
);
void setCircleNumber(int n);
//--axes
void setAxesPen
(QColor color,
int w ,
int penStyle
);
//--circles
void addCircles(int r, int n, int s, int e);
........//the rest
#ifndef OBJECTS_H
#define OBJECTS_H
#include <QWidget>
#include <QColor>
QT_BEGIN_NAMESPACE
class QVBoxLayout;
QT_END_NAMESPACE
class QSubWidget;
class CirclesGraphicsScene;
class CirclesGraphicsView;
//! [0]
class Circles : public QWidget
{
Q_OBJECT
Q_CLASSINFO("ClassID", "{d574a747-8016-46db-a07c-b2b4854ee75c}")
Q_CLASSINFO("InterfaceID", "{4a30719d-d9c2-4659-9d16-67378209f822}")
Q_CLASSINFO("EventsID", "{4a30719d-d9c2-4659-9d16-67378209f823}")
Q_PROPERTY(QColor backgroundColor READ backgroundColor WRITE setBackgroundColor)
Q_PROPERTY(int circleNumber READ circleNumber WRITE setCircleNumber)
void createScene();
public:
Circles(QWidget *parent = 0);
QSize sizeHint() const;
QColor backgroundColor()const;
int circleNumber()const{return _n;}
public slots:
//--general
void setBackgroundColor(QColor color);
void setCircleNumber(int n);
//--axes
void setAxesPen(QColor color, int w , int penStyle);
//--circles
void addCircles(int r, int n, int s, int e);
........//the rest
To copy to clipboard, switch view to plain text mode
Bookmarks