HISE Logo Forum
    • Categories
    • Register
    • Login

    JSON/Object from string

    Scheduled Pinned Locked Moved General Questions
    5 Posts 3 Posters 340 Views
    Loading More Posts
    • 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.
    • LindonL
      Lindon
      last edited by Lindon

      OK, follow up question. So I have my RSA encrypted JSON, I can decrypt it, and I get back a string like this:

      {"SerialNumber": "ABCDABCDABCDABCD", "ExpirationDate": "2023-01-18T05:25:43.511Z"}
      

      Now I want to turn this into an object so I can reference like this:

      if(myObj.SerialNumber == "ABCDABCDABCDABCD")
      {
        // do something funky
      }
      

      So is there any way to get a string into an object? Essentially Javascript's JSON.parse(string);

      HISE Development for hire.
      www.channelrobot.com

      d.healeyD 1 Reply Last reply Reply Quote 0
      • d.healeyD
        d.healey @Lindon
        last edited by

        Link Preview Image
        JSON.parse or parseJSON

        Is there a way to convert a string to JSON? If not, could we get one?

        favicon

        Forum (forum.hise.audio)

        Libre Wave - Freedom respecting instruments and effects
        My Patreon - HISE tutorials
        YouTube Channel - Public HISE tutorials

        LindonL P 2 Replies Last reply Reply Quote 1
        • LindonL
          Lindon @d.healey
          last edited by Lindon

          @d-healey - oh very nice - thank you....given the dates on that thread I'm only 12 months behind you now!!

          HISE Development for hire.
          www.channelrobot.com

          1 Reply Last reply Reply Quote 1
          • P
            parabuh @d.healey
            last edited by

            @d-healey does this still work? or has been replaced by some different method? I checked api docs and didnt see anything.

            Screenshot 2024-01-14 at 13.01.50.png

            d.healeyD 1 Reply Last reply Reply Quote 0
            • d.healeyD
              d.healey @parabuh
              last edited by

              @parabuh Nothing's changed as far as I'm aware

              Libre Wave - Freedom respecting instruments and effects
              My Patreon - HISE tutorials
              YouTube Channel - Public HISE tutorials

              1 Reply Last reply Reply Quote 0
              • First post
                Last post

              29

              Online

              1.8k

              Users

              12.1k

              Topics

              104.9k

              Posts