Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Labelling a Check Box using output from Text Input component

New Here ,
Jun 04, 2022 Jun 04, 2022

Hello, 

I've started working on an like a checklist or shopping list. You write what you want into the Textinput component and when you press done it will be what the check box is called. (if that makes sense). Is there a way to do it? Thanks for any help!!

TOPICS
ActionScript , Code , How to
79
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jun 04, 2022 Jun 04, 2022
LATEST

if your textinput has instance name ti and your checkbox instance name is cb, you can call doneF();

 

function doneF(){
document.getElementById("cb").nextSibling.outerHTML = '<label for="cb" style="box-sizing: border-box;">'+document.getElementById("ti")+'</label>'
}

 

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines