• Products
    • Isadora
    • Get It
    • ADD-ONS
    • IzzyCast
    • Get It
  • Forum
  • Help
  • Werkstatt
  • Newsletter
  • Impressum
  • Dsgvo
  • Press
  • Isadora
  • Get It
  • ADD-ONS
  • IzzyCast
  • Get It
  • Press
  • Dsgvo
  • Impressum
FORUM

Navigation

    • Register
    • Login
    • Search
    • Categories
    • Recent
    • Popular
    • Tags

    [ANSWERED] Using Javascript to split a text string

    How To... ?
    3
    4
    401
    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.
    • T
      tingkumajique last edited by Woland


      Hi all,

      I'm trying to figure out why my javascript is not working properly.


      I have a string of text that is "participant name | 012" and I'm trying to use javascript to split the string into
      1. participant name
      2. index number
      using the split function

      However, I"m not getting the intended results as shown in the screenshot. I'm either sometimes getting the Name or Index only.

      Any help would be greatly appreciated. Thanks!

      Juriaan bonemap 2 Replies Last reply Reply Quote 0
      • Juriaan
        Juriaan Tech Staff @tingkumajique last edited by

        @tingkumajique

        You have to mutate the outputs of the JavaScript actor to Text if you are working with text, you could simply do this by connecting any text input to the output field.

        Isadora 3.1.1, Dell XPS 17 9710, Windows 10
        Interactive Performance Designer, Freelance Artist, Scenographer, Lighting Designer, TroikaTronix Community moderator
        Always in for chatting about interaction in space / performance design. Drop me an email at hello@juriaan.me

        1 Reply Last reply Reply Quote 0
        • bonemap
          bonemap Izzy Guru @tingkumajique last edited by

          @tingkumajique

          Hi,

          I put together a demo patch of Javascript text separation and joining options - its available to download from the Add-ons page. But here is one that might be useful: js-text-separator.zip

          Best Wishes,

          Russell

          http://bonemap.com | Australia
          Izzy STD 4.2 | USB 3.6 | + Beta
          MBP 16” 2019 2.4 GHz Intel i9 64GB AMD Radeon Pro 5500 8 GB 4TB SSD | 14.5 Sonoma
          Mac Studio 2023 M2 Ultra 128GB | OSX 15.3 Sequoia
          A range of deployable older Macs

          1 Reply Last reply Reply Quote 1
          • T
            tingkumajique last edited by

            Ah thanks all for the pointers and examples :)

            Appreciate this community in my Isadora journey!

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