12/13/2023 8:46 PM | |
Joined: 3/16/2021 Last visit: 4/24/2025 Posts: 7 Rating:
|
Follow up question! If i want to read out the screen name, or screen number from a screen window, and write this to a tag, how do I do that? ------------------------------------------------------------------------------------------ |
Last edited by: Jen_Moderator at: 01/03/2024 13:38:02New subject after splitting |
|
12/14/2023 8:03 AM | |
Joined: 1/21/2013 Last visit: 4/25/2025 Posts: 3775 Rating:
|
Hi nilsig, To read the screen name or number, the ScreenWindow provides the ScreenName and ScreenNumber properties. Kind regards |
This contribution was helpful to
1 thankful Users |
1/15/2024 6:28 PM | |
Joined: 1/21/2013 Last visit: 4/25/2025 Posts: 3775 Rating:
|
Hi nilsig, Knowing only a few small snippets of code makes it difficult to give proper feedback. However, a construct like
is new to me. I doubt it will be supported. To get a "ScreenWindow" object, the FindItem() method is usually used. Maybe this will help:
Kind regards |
This contribution was helpful to
1 thankful Users |
1/16/2024 5:30 AM | |
Joined: 1/21/2013 Last visit: 4/25/2025 Posts: 3775 Rating:
|
Hi nilsig, In my example, I used the optional chaining (?.) operator. If the FindItem method cannot find an object with the given path, there will be no ScreenName property. Without the optional chaining, this would throw an exception. However, with the optional chaining, the result is undefined without throwing an exception. It is important to ensure that the rest of the script can handle this undefined value. Kind regards |
Follow us on