cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
  • Instantly extract effect sizes, F-ratios, and FDR-adjusted p-values from your models with the Calculate Effects Sizes extension, available now in the JMP Marketplace!
  • New to JMP? Join us Sept. 23-24 for the Early User Edition of Discovery Summit, tailor-made for new users. Register now for free!
  • Your voice matters! Tell us how you prefer to receive JMP updates, so we can tailor our communication to your needs. Take short survey.

Discussions

Solve problems, and share tips and tricks with other JMP users.
Choose Language Hide Translation Bar
ben_ph
Level III

Running a TextEditBox's Set Text Changed script programmatically

Is it possible to run a TextEditBox's Set Text Changed script programmatically? I can use << setText("text", runscript(1)) if the TextEditBox's script is set with <<setFunction but not when it is set with <<setTextChanged.

 

 

Names Default To Here(1);
New Window("Example",
    teb = Text Edit Box("Example Text",
        <<Set Text Changed(Function({this, value}, (this << sib) << settext(value)))
    ),
    Text Box("")
);

teb << setText("test", runscript(1)) // Works for <<setFunction

 

Thanks for any help!

 

1 ACCEPTED SOLUTION

Accepted Solutions
ben_ph
Level III

Re: Running a TextEditBox's Set Text Changed script programmatically

This seems to work

Names Default To Here(1);
New Window("Example",
    teb = Text Edit Box("Example Text",
        <<Set Text Changed(Function({this, value}, (this << sib) << settext(value)))
    ),
    Text Box("")
);

teb << setText("abc");
f = teb << getTextChanged();
f(teb, "abc")

View solution in original post

1 REPLY 1
ben_ph
Level III

Re: Running a TextEditBox's Set Text Changed script programmatically

This seems to work

Names Default To Here(1);
New Window("Example",
    teb = Text Edit Box("Example Text",
        <<Set Text Changed(Function({this, value}, (this << sib) << settext(value)))
    ),
    Text Box("")
);

teb << setText("abc");
f = teb << getTextChanged();
f(teb, "abc")

Recommended Articles