Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. (Qt5) JSON.stringify call Error. Error message is "Converting circular structure to JSON"
Forum Update on Monday, May 27th 2025

(Qt5) JSON.stringify call Error. Error message is "Converting circular structure to JSON"

Scheduled Pinned Locked Moved QML and Qt Quick
1 Posts 1 Posters 1.6k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    Bob Wang
    wrote on 9 Dec 2013, 07:19 last edited by
    #1

    Anybody can help me?
    @main.qml

    import QtQuick 2.0
    import QtQuick.Controls 1.0
    import QtQuick.Layouts 1.0
    Rectangle {
    Button{
    id: testButton
    text:"Test"
    }
    Text{
    id: testText
    text:"TEST"
    }

    Component.onCompleted: {
        console.log("JSON data = " + JSON.stringify(testText));   //It's OK
        console.log("JSON data = " + JSON.stringify(testButton)); //Get an error "TypeError: Converting circular structure to JSON"
    }
    

    }@

    1 Reply Last reply
    0

    1/1

    9 Dec 2013, 07:19

    • Login

    • Login or register to search.
    1 out of 1
    • First post
      1/1
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved