<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Unknown method return type for registered type]]></title><description><![CDATA[<p dir="auto">I have the following main.cpp</p>
<p dir="auto">@int main(int argc, char *argv[])<br />
{<br />
QGuiApplication app(argc, argv);</p>
<pre><code>QtQuick2ApplicationViewer viewer;

qmlRegisterType&lt;project::Model&gt;("com.company.project", 1, 0, "Model");
qmlRegisterType&lt;project::Run&gt;("com.company.project", 1, 0, "Run");

viewer.setMainQmlFile&amp;#40;QStringLiteral("qml/ProjectQml/main.qml"&amp;#41;);
viewer.showExpanded();

return app.exec();
</code></pre>
<p dir="auto">}@</p>
<p dir="auto">And the following snippet in main.qml</p>
<p dir="auto">@Project.Model {<br />
id: projectModel<br />
}</p>
<pre><code>FileDialog {
    id: fileDialog
    title: "Please choose a file"
    selectFolder: true
    onAccepted: {
        console.log("You chose: " + fileDialog.fileUrl)
        var run = projectModel.startLoadingRun(fileDialog.fileUrl)
    }
    onRejected: {
        console.log("Canceled")
    }
}@
</code></pre>
<p dir="auto">When I reach the "var run = exegesisModel.startLoadingRun(fileDialog.fileUrl)" line I get the error Error: Unknown method return type: Run*</p>
]]></description><link>https://forum.qt.io/topic/38335/unknown-method-return-type-for-registered-type</link><generator>RSS for Node</generator><lastBuildDate>Sat, 02 May 2026 04:20:28 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/38335.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 26 Feb 2014 19:20:04 GMT</pubDate><ttl>60</ttl></channel></rss>